bugGNU Octave - Bugs: bug #47587, virtual function "message...

 
 

bug #47587: virtual function "message (void)" not defined by classes inheriting from "index_exception"

Submitter:  Markus Mützel <mmuetzel>
Submitted:  Thu 31 Mar 2016 05:02:29 PM UTC
   
 
Category:  Libraries Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Build Failure
Status:  Invalid / Not an Octave Bug Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * dev Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 31 Mar 2016 07:25:19 PM UTC, comment #3: 

Closing as you suggested, but thanks for taking a look at the visibility patch.  We would like to get it working.

Rik <rik5>
Group administrator
Thu 31 Mar 2016 07:17:18 PM UTC, comment #2: 

Please, close as invalid. This only applies to patch #8919.

Markus Mützel <mmuetzel>
Group administrator
Thu 31 Mar 2016 06:21:55 PM UTC, comment #1: 

I realized a few minutes after posting this report that "index_exception::message" is defined in "lo-array-errwarn.cc". So index_exception_v2.patch" does not compile.

Now, I do not know why I see the "undefined reference to typeinfo" error when compiling with visibility attributes. I'll see whether I can find some info...

Markus Mützel <mmuetzel>
Group administrator
Thu 31 Mar 2016 05:02:29 PM UTC, original submission:  

While looking into patch #8919 (enable visibility attributes for GCC in build system) and fiddling around with the visibility flags, I came to a point where the linker threw the error "undefined reference to typeinfo" for the function "message" in class "index_exception". After following the hints in e.g. [1] and making it a pure virtual function, other errors were thrown because "message" was not defined for many classes inheriting from "index_exception".

I fixed this by explicitly defining "message" in the five instances I found ("index_exception_v1.patch").

Another possible approach [1] would be to define the function "message" in class "index_exception" to give a standard implementation for inheriting classes ("index_exception_v2.patch").

I do not know which approach is the better one and am going to attach the two alternative patches as soon as I have the bug number.

[1] http://stackoverflow.com/questions/307352/g-undefined-reference-to-typeinfo

Markus Mützel <mmuetzel>
Group administrator

 

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

Attach Files:
   
   
Comment:
   

Attached Files

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by mmuetzel (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-03-31 rik5 StatusNone Invalid / Not an Octave Bug
        Open/ClosedOpen Closed
    2016-03-31 mmuetzel Attached File- Added index_exception_v1.patch, #36811
        Attached File- Added index_exception_v2.patch, #36812

    Back to the top

    Powered by Savane 3.13-758e.
    Corresponding source code