Menu

#5923 Use a hash table for the lexer keywords

Started
None
abandoned
2020-05-02
2020-04-20
No

Get rid of unused function ly:lexer-keywords.

https://codereview.appspot.com/549920043

Related

Issues: #5923

Discussion

  • Han-Wen Nienhuys

     
  • Anonymous

    Anonymous - 2020-04-20
    • Description has changed:

    Diff:

    
    
    • Needs: -->
    • Patch: new --> needs_work
    • Type: -->
     
  • Anonymous

    Anonymous - 2020-04-20

    This just sits at

    ...
    langdefs.py: warning: lilypond-doc gettext domain not found.
    langdefs.py: warning: lilypond-doc gettext domain not found.
    langdefs.py: warning: lilypond-doc gettext domain not found.
    langdefs.py: warning: lilypond-doc gettext domain not found.
    lilypond-book.py: error: file not found: markup-commands.tely
    
    /home/james/lilypond-git/build/.././make/ly-rules.make:24: recipe for target 'out/notation.texi' failed
    make[1]: *** [out/notation.texi] Error 1
    make[1]: *** Deleting file 'out/notation.texi'
    make[1]: *** Waiting for unfinished jobs....
    

    and makes my fan spin very loudly.

     
    • Jonas Hahnfeld

      Jonas Hahnfeld - 2020-04-20

      Okay, so it's not just me hitting that thing. There's a missing dependency in the Documentation build that's probably uncovered by recent performance improvements in LilyPond. I don't think it's this patch. If you didn't prune your tree yet, you may just retry running 'make doc' and hope that internals.texi is processed first. I'll submit a proper fix tomorrow.

       
  • Jonas Hahnfeld

    Jonas Hahnfeld - 2020-04-21
    • Patch: needs_work --> new
    • Type: --> Enhancement
     
  • Jonas Hahnfeld

    Jonas Hahnfeld - 2020-04-21

    @lilypond-pkx could you please try again? The error you saw should now be fixed in master.

     
  • Anonymous

    Anonymous - 2020-04-21
    • Patch: new --> needs_work
     
  • Anonymous

    Anonymous - 2020-04-21

    Now it just sits at

    ...
    Making Documentation/out/contributor.texi (copy)
    Making Documentation/out/web.texi (copy)
    Making Documentation/out/changes.texi < tely
    Making Documentation/out/internals.texi 
    Making Documentation/out/essay.texi < tely
    Making Documentation/out/music-glossary.texi < tely
    Making Documentation/out/learning.texi < tely
    langdefs.py: warning: lilypond-doc gettext domain not found.
    Making Documentation/out/usage.texi < tely
    langdefs.py: warning: lilypond-doc gettext domain not found.
    Making Documentation/out/extending.texi < tely
    langdefs.py: warning: lilypond-doc gettext domain not found.
    Making Documentation/out/snippets.texi < tely
    langdefs.py: warning: lilypond-doc gettext domain not found.
    langdefs.py: warning: lilypond-doc gettext domain not found.
    langdefs.py: warning: lilypond-doc gettext domain not found.
    langdefs.py: warning: lilypond-doc gettext domain not found.
    

    when running 'make'

     
  • Han-Wen Nienhuys

    can you tell us which job is spinning? Try 'top' to see what the machine is busy doing.
    
     
    • Jonas Hahnfeld

      Jonas Hahnfeld - 2020-04-27

      From the logs, it's one of the lilypond-book processes in Documentation, didn't test myself though. Did you try to run 'make doc' on your end? As the change is removing ly:lexer-keywords it could also be that it breaks generation of the internals reference manual.

       
      • Han-Wen Nienhuys

        I can repro it now, sorry for the noise.

        On Mon, Apr 27, 2020 at 10:34 AM Jonas Hahnfeld
        hahnjo@users.sourceforge.net wrote:

        From the logs, it's one of the lilypond-book processes in Documentation, didn't test myself though. Did you try to run 'make doc' on your end? As the change is removing ly:lexer-keywords it could also be that it breaks generation of the internals reference manual.


        [issues:#5923] Use a hash table for the lexer keywords

        Status: Started
        Created: Mon Apr 20, 2020 08:10 AM UTC by Han-Wen Nienhuys
        Last Updated: Mon Apr 27, 2020 08:27 AM UTC
        Owner: Han-Wen Nienhuys

        Get rid of unused function ly:lexer-keywords.

        https://codereview.appspot.com/549920043


        Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/testlilyissues/issues/5923/

        To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/

         

        Related

        Issues: #5923

  • Han-Wen Nienhuys

    drop table from lexer class

    https://codereview.appspot.com/549920043

     
  • Han-Wen Nienhuys

     
  • Anonymous

    Anonymous - 2020-04-27
    • Needs: -->
    • Patch: new --> needs_work
    • Type: -->
     
  • Anonymous

    Anonymous - 2020-04-27

    Fails make

    ...
    Making lily/out/lily-lexer.o < cc
    Making lily/out/metronome-engraver.o < cc
    Making lily/out/warn-scheme.o < cc
    /home/james/lilypond-git/lily/lily-lexer.cc:47:13: error: 'unordered_map' in namespace 'std' does not name a template type
     static std::unordered_map<std::string, int> keytable{
                 ^~~~~~~~~~~~~
    /home/james/lilypond-git/lily/lily-lexer.cc: In member function 'int Lily_lexer::lookup_keyword(const string&)':
    /home/james/lilypond-git/lily/lily-lexer.cc:183:20: error: 'keytable' was not declared in this scope
       auto const &it = keytable.find (s);
                        ^~~~~~~~
    /home/james/lilypond-git/lily/lily-lexer.cc:183:20: note: suggested alternative: 'mutable'
       auto const &it = keytable.find (s);
                        ^~~~~~~~
                        mutable
    Making lily/out/lexer.o < cc
    /home/james/lilypond-git/build/../stepmake/stepmake/c++-rules.make:4: recipe for target 'out/lily-lexer.o' failed
    make[1]: *** [out/lily-lexer.o] Error 1
    make[1]: *** Waiting for unfinished jobs....
    out/lexer.cc: In member function 'virtual int yyFlexLexer::LexerInput(char*, int)':
    out/lexer.cc:6476:21: warning: conversion to 'int' from 'std::streamsize {aka long int}' may alter its value [-Wconversion]
       return yyin.gcount();
              ~~~~~~~~~~~^~
    /home/james/lilypond-git/build/../stepmake/stepmake/generic-targets.make:6: recipe for target 'all' failed
    make: *** [all] Error 2
    
     
  • Han-Wen Nienhuys

     
  • Anonymous

    Anonymous - 2020-04-28
    • Needs: -->
    • Patch: new --> review
    • Type: -->
     
  • Anonymous

    Anonymous - 2020-04-28

    Passes make, make check and a full make doc.

     
  • Anonymous

    Anonymous - 2020-04-30
    • Patch: review --> countdown
     
  • Anonymous

    Anonymous - 2020-04-30

    Patch on countdown for May 2nd - not comments on Rietveld from David K

     
  • Anonymous

    Anonymous - 2020-05-02
    • Patch: countdown --> push
     
  • Anonymous

    Anonymous - 2020-05-02

    Patch counted down - please push

     
  • Jonas Hahnfeld

    Jonas Hahnfeld - 2020-05-02

    Han-Wen, David, shall we close this as Issue 5946 is now in staging?

     
    • David Kastrup

      David Kastrup - 2020-05-02

      I think that would make sense. I already have the promised followup issue removing ly:lexer-keywords in a branch and wanted for staging to get through before I bring it up.

       
  • Han-Wen Nienhuys

    • Patch: push --> abandoned
     
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.