#154 Breakage on attribute after parenthesis

GNADE 1.X
closed
7
2007-10-04
2007-09-17
No

When GESQL 1.5.3b encounters an attribute following a parenthesis it deletes the attribute and the rest of the line. Then it deletes all the line breaks from that point to the next apostrophe.

Discussion

  • Björn Persson

    Björn Persson - 2007-09-17

    before

     
  • Björn Persson

    Björn Persson - 2007-09-17

    after

     
  • Björn Persson

    Björn Persson - 2007-09-17

    Logged In: YES
    user_id=1037163
    Originator: YES

    File Added: gesqltest.adb

     
  • Björn Persson

    Björn Persson - 2007-09-17
    • priority: 5 --> 7
     
  • Michael Erdmann

    Michael Erdmann - 2007-09-17

    Logged In: YES
    user_id=146097
    Originator: NO

    I really can't see where the offending construct is. I have
    tested this code and it works with the version i am using.

    procedure Test is
    type T_Access is access Integer;

    T : T_Access := new Integer'(0);
    begin
    T : T + 1;
    end;

    Please could you provide an isolated example.

     
  • Björn Persson

    Björn Persson - 2007-09-17

    Logged In: YES
    user_id=1037163
    Originator: YES

    Sorry, I thought I didn't need to be more precise because I thought it would be easy to find the extremely long line where the line breaks were deleted.

    The problem is with the expression "Length(Data.Tail)'Img" on line 396 of gesqltest.adq. In gesqltest.adb it's line 388.

     
  • Björn Persson

    Björn Persson - 2007-09-17

    test case 1

     
  • Björn Persson

    Björn Persson - 2007-09-17

    Logged In: YES
    user_id=1037163
    Originator: YES

    Here's a short test case.
    File Added: short1.adq

     
  • Björn Persson

    Björn Persson - 2007-09-17

    Logged In: YES
    user_id=1037163
    Originator: YES

    And here's what GESQL produced. Note what happened to the words "is nice".
    File Added: short1.adb

     
  • Björn Persson

    Björn Persson - 2007-09-17

    output of test case 1

     
  • Björn Persson

    Björn Persson - 2007-09-17

    test case 2

     
  • Björn Persson

    Björn Persson - 2007-09-17

    Logged In: YES
    user_id=1037163
    Originator: YES

    With a subtle change inside a string literal I get very different behavior:

    $ gesql short2.adq

    GNADE Embedded SQL (GESQL) Ada 95 Translator Version 1.5.3b
    Copyright (C) 2000-2003 Michael Erdmann

    short2.adq:18:19: error : end of file in string starting at 15
    short2.adq:18:19: warning : Exception SCANNER.LEXICAL_ERROR occured
    short2.adq:18:19: warning : scanner.adb:527
    short2.adq:18:19:Fatal error, uncatched exception SCANNER.LEXICAL_ERROR occured
    short2.adq:18:19:*** Processing of file aborted ***

    Processed 1 of 1 file(s) not successfully, 0 error(s)

    File Added: short2.adq

     
  • Michael Erdmann

    Michael Erdmann - 2007-09-19

    Logged In: YES
    user_id=146097
    Originator: NO

    Your bug has been fixed, please retest with the next release.

     
  • Michael Erdmann

    Michael Erdmann - 2007-09-19

    Logged In: YES
    user_id=146097
    Originator: NO

    Corrected on the 1.5.3b branch

     
  • Michael Erdmann

    Michael Erdmann - 2007-09-19
    • assigned_to: nobody --> merdmann
    • status: open --> pending
     
  • SourceForge Robot

    Logged In: YES
    user_id=1312539
    Originator: NO

    This Tracker item was closed automatically by the system. It was
    previously set to a Pending status, and the original submitter
    did not respond within 14 days (the time period specified by
    the administrator of this Tracker).

     
  • SourceForge Robot

    • status: pending --> closed
     
  • Nobody/Anonymous

    I've the same problem with the 1.5.3b release.

    The apostrope within the constant string with the same problem as sample program short2.gpq

     
  • Adriano Colaianni

    Same problems with the attribute following parenthesis.
    Release of gnade compiled from source tarball 1.5.3b

    from source:

    .....
    RETURN codice(1..ind_ultimo_carattere) &
    (1..integer(codice'LENGTH) - ind_ultimo_carattere -
    (integer'IMAGE(codice_corrente)'LENGTH-integer(1)) => '0') &
    integer'IMAGE(codice_corrente)
    (2..(integer'IMAGE(codice_corrente))'LENGTH);
    ......

    after the gesql

    ......
    RETURN codice(1..ind_ultimo_carattere) &
    (1..integer(codice'LENGTH) - ind_ultimo_carattere -
    (integer'IMAGE(codice_corrente)'LENGTH-integer(1)) => '0') &
    integer'IMAGE(codice_corrente)
    (2..(integer'IMAGE(codice_corrente))
    end next_codice;
    .........

     

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