#222 Unit Test for bn_poly_scale

Untested
closed-accepted
None
5
2013-08-06
2013-07-31
Nyah Check
No

this adds a unit test for bn_poly_scale() routine into BRL-CAD

1 Attachments

Discussion

  • Nyah Check

    Nyah Check - 2013-08-02

    modified patch with original references from octave

     
    Last edit: Nyah Check 2013-08-03
  • Nyah Check

    Nyah Check - 2013-08-05

    this patch should be applied after ticket 221. which moves the comments on standard values generated from Octave to poly_init() routine.

     
  • Nyah Check

    Nyah Check - 2013-08-05

    updated patch

     
  • Nyah Check

    Nyah Check - 2013-08-05

    updated

     
  • Nyah Check

    Nyah Check - 2013-08-05

    most recent changes

     
  • Nyah Check

    Nyah Check - 2013-08-05

    errors removed

     
  • Nyah Check

    Nyah Check - 2013-08-05

    updated

     
  • Nyah Check

    Nyah Check - 2013-08-05

    updated version

     
  • Erik Greenwald

    Erik Greenwald - 2013-08-06

    almost there, you also need to fix where there is more than one indentation level. (one level of indentation is 4 spaces, two levels of indentation should be one tab, 3 levels of indentation should be a tab followed by 4 spaces, 4 levels should be two tabs, etc...).

     
  • Nyah Check

    Nyah Check - 2013-08-06

    here is the modified with all the changes you've intructed.

     
  • Erik Greenwald

    Erik Greenwald - 2013-08-06

    the tabs are still not in place. I'll try to explain it by showing a piece of your code as C strings... You have:
    " for (i = 0; i < n; i++) {\n"
    " if (!EQUAL(a[i],b[i]))\n"
    " return -1;\n"
    it should look more like
    " for (i = 0; i < n; i++) {\n"
    "\tif (!EQUAL(a[i],b[i]))\n"
    "\t return -1;\n"
    It's entirely possible that you used the 'tab' key and gedit translate it to spaces for you, I'm not familiar with gedit so I don't know if it does that and if there is an option to change behavior. Emacs and vim can do the right thing (the vim command to apply it to a file would be something like ":%s/[ ]{8}/\t/g".

    Also; lines 141-143 should be collapsed into a single line, " } else"

     
  • Nyah Check

    Nyah Check - 2013-08-06

    Also; lines 141-143 should be collapsed into a single line, " } else"

    Alright, could you please fix this patch yourself; so I'll use it as a
    reference in fixing the other patches since i have about 7 more to go.

    Cheers!
    Nyah

     
  • Nyah Check

    Nyah Check - 2013-08-06

    will see what i can do..

     
  • Nyah Check

    Nyah Check - 2013-08-06

    updated

     
  • Nyah Check

    Nyah Check - 2013-08-06

    updated

     
  • Nyah Check

    Nyah Check - 2013-08-06

    after running through ws.sh

     
  • Nyah Check

    Nyah Check - 2013-08-06

    new patch

     
  • Sean Morrison

    Sean Morrison - 2013-08-06
    • status: open --> closed-accepted
     
  • Sean Morrison

    Sean Morrison - 2013-08-06

    applied in r56638 with fixes in 56639 and 56640

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks