Mirror of https://github.com/leanprover/lean2 in case it ever disappears
Find a file
Leonardo de Moura b3e05a2fe9 refactor(frontends/lean/scanner): remove dependency to seekg and unget
methods

It is not safe to use seekg for textual files. Here is a fragment from a
C++ manual:

seekg() and seekp()

This pair of functions serve respectively to change the position of stream pointers get and put. Both functions are overloaded with two different prototypes:

     seekg ( pos_type position );
     seekp ( pos_type position );

Using this prototype the stream pointer is changed to an absolute position from the beginning of the file. The type required is the same as that returned by functions tellg and tellp.

      seekg ( off_type offset, seekdir direction );
      seekp ( off_type offset, seekdir direction );

Using this prototype, an offset from a concrete point determined by
parameter direction can be specified. It can be:

          ios::beg	offset specified from the beginning of the stream
          ios::cur	offset specified from the current position of the stream pointer
          ios::end	offset specified from the end of the stream

The values of both stream pointers get and put are counted in different
ways for text files than for binary files, since in text mode files some
modifications to the appearance of some special characters can
occur. For that reason it is advisable to use only the first prototype
of seekg and seekp with files opened in text mode and always use
non-modified values returned by tellg or tellp. With binary files, you
can freely use all the implementations for these functions. They should
not have any unexpected behavior.
2014-09-18 15:24:48 -07:00
bin fix(bin/ltags): handle recursor specially in tags generation 2014-09-15 15:17:46 -07:00
doc feat(frontends/lean/server): add SYNC command, closes #199 2014-09-16 18:42:34 -07:00
images chore(*): add logo 2014-04-29 16:21:17 -07:00
library feat(frontends/lean): split 'opaque_hint' command into 'opaque' and 'transparent' 2014-09-16 18:03:40 -07:00
script fix(script/demangle_cpptype): process line-by-line, instead of waiting for EOF 2013-09-29 18:36:01 -07:00
src refactor(frontends/lean/scanner): remove dependency to seekg and unget 2014-09-18 15:24:48 -07:00
tests refactor(frontends/lean/scanner): remove dependency to seekg and unget 2014-09-18 15:24:48 -07:00
.gitignore chore(.gitignore): add .lean_options 2014-09-04 15:04:57 -07:00
.travis.osx.yml chore(.travis.osx.yml): update homebrew lua package names 2014-09-17 00:49:32 -07:00
.travis.windows.yml chore(travis): use lean-build@googlegroups 2014-05-02 17:21:54 -04:00
.travis.yml chore(.travis): install valgrind before we install c++ compiler 2014-09-10 09:47:43 -07:00
LICENSE Add LICENSE file 2013-07-15 18:55:48 -07:00
README.md refactor(library): set up and document standard/classical/hott imports 2014-08-25 22:57:55 -07:00

logo

LicenseUbuntuOS XWindowsCoverageBuilds/TestsStatic Analysis
Coverity Scan Build Status

About

Requirements

Installing required packages at

Build Instructions

Miscellaneous