bugGNU Octave - Bugs: bug #51192, static class method argument...

 
 

bug #51192: static class method argument inaccessible

Submitted by:  A.R. Burgers <arb>
Submitted on:  Tue 06 Jun 2017 08:15:59 PM UTC  
 
Category: InterpreterSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Regression
Status: FixedAssigned to: None
Originator Name: Open/Closed: Closed
Release: devOperating System: Any

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Fri 21 Jul 2017 03:53:04 PM UTC, comment #9:

I folded the two changesets into one and pushed them here (http://hg.savannah.gnu.org/hgweb/octave/rev/711227992c1d). Thanks Piotr for tracing this down and then coding a solution. Marking as fixed and closing report.

Rik <rik5>
Project Administrator
Fri 21 Jul 2017 12:21:54 AM UTC, comment #8:

I added the two changsets: 1 with the bugfix and the other with the test and a comment to the bugfix.

Piotr Held <jsoh425>
Thu 20 Jul 2017 11:29:22 PM UTC, comment #7:

Not only should this get fixed, but we should add a test in the test/ directory for this bug. See the directory test/bug-44940 for an example.

Rik <rik5>
Project Administrator
Thu 20 Jul 2017 05:58:52 PM UTC, comment #6:

I'm working on this problem and I think I found the culprit. It's line libinterp/parse-tree/pt-eval.cc:1267 in the broken changeset. When you call a static method on an object the 'indexing_object' variable is true, but when you call it on a class name it is false. I am trying to find the fix and will post a changeset once I do.

Piotr Held <jsoh425>
Thu 20 Jul 2017 05:54:27 PM UTC, comment #5:

I'm adding jwe to the CC list for this report since he was the author of 23521:551fa3879615. After reading the comments on the check-in, I can believe that it is related.

Rik <rik5>
Project Administrator
Thu 20 Jul 2017 12:31:18 AM UTC, comment #4:

I believe the bug is in changeset 23521:551fa3879615, that is before this changeset static methods work and after it they don't.

Piotr Held <jsoh425>
Fri 16 Jun 2017 08:58:54 PM UTC, comment #3:

Invoking the static method with help of an instance does still work

A.R. Burgers <arb>
Fri 09 Jun 2017 08:33:15 PM UTC, comment #2:

Confirmed.

Rik <rik5>
Project Administrator
Fri 09 Jun 2017 06:29:54 AM UTC, comment #1:

the cs classdef is simple and defines just a single static method.

invoking the static method with cs.pval(10) leads to the 'val' undefined message below in current dev

A.R. Burgers <arb>
Tue 06 Jun 2017 08:15:59 PM UTC, original submission:

in current dev arguments to static methods are undefined.

with dev:

with stable:

A.R. Burgers <arb>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #41270:  test.diff added by jsoh425 (3KiB - text/x-patch - This is the changeset with the tests and comment for the bugfix)
file #41269:  bugfix.diff added by jsoh425 (1003B - text/x-patch - This is the bugfix changeset. I will add the test changset shortly)
file #40865:  cs.m added by arb (85B - application/octet-stream)
file #40866:  rcs.m added by arb (49B - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by rik5 (Take a look at cset 23521:551fa3879615)
  • -unavailable- added by jsoh425 (Posted a comment)
  • -unavailable- added by rik5 (Posted a comment)
  • -unavailable- added by arb (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 8 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Fri 21 Jul 2017 03:53:04 PM UTCrik5StatusConfirmed=>Fixed
      Open/ClosedOpen=>Closed
    Fri 21 Jul 2017 12:20:45 AM UTCjsoh425Attached File-=>Added test.diff, #41270
    Thu 20 Jul 2017 11:47:34 PM UTCjsoh425Attached File-=>Added bugfix.diff, #41269
    Thu 20 Jul 2017 05:55:38 PM UTCrik5Carbon-Copy-=>Added jwe
    Fri 09 Jun 2017 08:33:15 PM UTCrik5StatusNone=>Confirmed
    Tue 06 Jun 2017 08:15:59 PM UTCarbAttached File-=>Added cs.m, #40865
      Attached File-=>Added rcs.m, #40866

    Back to the top


    Powered by Savane 3.1-cleanup1