[yt-svn] commit/yt: MatthewTurk: Updating coding styleguide.

Bitbucket commits-noreply at bitbucket.org
Mon Sep 10 10:59:46 PDT 2012


1 new commit in yt:


https://bitbucket.org/yt_analysis/yt/changeset/d87439267be6/
changeset:   d87439267be6
branch:      yt
user:        MatthewTurk
date:        2012-09-10 19:59:42
summary:     Updating coding styleguide.
affected #:  1 file

diff -r e6986d875c433ca3ab09e7070c1a06c7e7c7eef1 -r d87439267be6e6c2d2f2fb4c6a077b6a075c6900 doc/coding_styleguide.txt
--- a/doc/coding_styleguide.txt
+++ b/doc/coding_styleguide.txt
@@ -18,7 +18,7 @@
    Python is more forgiving than C.
  * Avoid copying memory when possible. For example, don't do 
    "a = a.reshape(3,4)" when "a.shape = (3,4)" will do, and "a = a * 3" should
-   be "na.multiply(a, 3, a)".
+   be "np.multiply(a, 3, a)".
  * In general, avoid all double-underscore method names: __something is usually
    unnecessary.
  * When writing a subclass, use the super built-in to access the super class,
@@ -40,8 +40,7 @@
 
    from yt.visualization.plot_collection import PlotCollection
 
- * Numpy is to be imported as "na" not "np".  While this may change in the
-   future, for now this is the correct idiom.
+ * Numpy is to be imported as "np", after a long time of using "na".
  * Do not use too many keyword arguments.  If you have a lot of keyword
    arguments, then you are doing too much in __init__ and not enough via
    parameter setting.

Repository URL: https://bitbucket.org/yt_analysis/yt/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.



More information about the yt-svn mailing list