octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unable to have get/set methods in classdef files


From: John W. Eaton
Subject: Re: Unable to have get/set methods in classdef files
Date: Thu, 23 Jan 2014 04:26:57 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20131005 Icedove/17.0.9

On 01/22/2014 07:04 AM, Michael Goffioul wrote:
On Wed, Jan 22, 2014 at 3:11 AM, John W. Eaton <address@hidden
<mailto:address@hidden>> wrote:

    On 01/18/2014 11:05 PM, Michael Goffioul wrote:

        Defining a get/set method in a classdef file results in a
        parsing error.
        I'm not sure what's the best way to solve this, but John if you
        can give
        me a hint, I'm willing to fix the issue.


    Can you give me a specific code example that shows the failure?


classdef clA
   methods
     function y = get (this)
       y = 0;
     end
   end
end

How about the attached changeset?  It seems to work for me.  If it
works for you, then apply it and push to savannah.

I didn't see a better way to avoid duplicating code in the new action
other than using a macro because it uses yyless and so I don't think
it can be executed outside of the action context.

jwe

Attachment: diffs.txt
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]