Giter Site home page Giter Site logo

gsoc-gcc-regex's People

Contributors

melges-morgen avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

gsoc-gcc-regex's Issues

Segmentation fault in TokenFactory

If you try to compile a regular expression \[a-z\] program send SIGSEGV.

Program received signal SIGSEGV, Segmentation fault.
0x000000000040b8b5 in __gnu_cxx::operator!=<std::__regex::_TokenFactory<std::regex_traits<char> > const*, std::vector<std::__regex::_TokenFactory<std::regex_traits<char> >, std::allocator<std::__regex::_TokenFactory<std::regex_traits<char> > > > > (
    __lhs=<error reading variable: Cannot access memory at address 0x7fffff7feff8>, 
    __rhs=<error reading variable: Cannot access memory at address 0x7fffff7feff0>)
    at /home/melges/Programs/gccRegexWorkspace/current-gcc-build/include/c++/4.8.0/bits/stl_iterator.h:825
825     operator!=(const __normal_iterator<_Iterator, _Container>& __lhs,

In backtrace more then 7000 calling to _M_alternative.

From libstdc++-v3/testsuite/28_regex/algorithms/01_compilation/01_basic_valid.cc:11

The same for (\[\[a-z\]\])*, (ss)s{s,s}\[dd\],

_M_scan_in_bracket failed on valid expression

_M_scan_in_bracket failed on (([a-c])+) expression: after analysis of [a-c] token _M_curToken is _S_token_collem_single but _S_token_subexpr_end was expected.

UPD 13.07.12
_M_scan_in_bracket fails on [a-z-A-Z]

locales, perforamance, measuring

Should all the scanner tokens be pre-cached? Right now, many of the tokens are using std::locale:: facets to get a result, and throwing away that locale-processed result. In other areas of the library, using locales without caching is slow.

Think about this issue from a design standpoint. At what point are things cached? What difference does it make? If we cannot measure any performance problems, then it doesn't make sense to measure it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.