- 10 Dec, 2003 8 commits
-
-
simonmar authored
oops, forgot a reverse
-
simonmar authored
Fix syntax error
-
simonmar authored
Cleanups: - Move the collect* functions from HsSyn into HsUtils. Check that we have a clean separation of utilties over HsSyn, with the generic versions in HsUtils, and the specific versions in RdrHsSyn, RnHsSyn and TcHsSyn as appropriate. - Remove the RdrBinding data type, which was really just a nested list with O(1) append, and use OrdList instead. This makes it much clearer that there's nothing strange going on. - Various other minor cleanups.
-
simonmar authored
fix bogosity spotted by -Wall
-
simonmar authored
New file of miscellaneous utility functions over HsSyn.
-
simonmar authored
Add accurate source location annotations to HsSyn ------------------------------------------------- Every syntactic entity in HsSyn is now annotated with a SrcSpan, which details the exact beginning and end points of that entity in the original source file. All honest compilers should do this, and it was about time GHC did the right thing. The most obvious benefit is that we now have much more accurate error messages; when running GHC inside emacs for example, the cursor will jump to the exact location of an error, not just a line somewhere nearby. We haven't put a huge amount of effort into making sure all the error messages are accurate yet, so there could be some tweaking still needed, although the majority of messages I've seen have been spot-on. Error messages now contain a column number in addition to the line number, eg. read001.hs:25:10: Variable not in scope: `+#' To get the full text span info, use the new option -ferror-spans. eg. read001.hs:25:10-11: Variable not in scope: `+#' I'm not sure whether we should do this by default. Emacs won't understand the new error format, for one thing. In a more elaborate editor setting (eg. Visual Studio), we can arrange to actually highlight the subexpression containing an error. Eventually this information will be used so we can find elements in the abstract syntax corresponding to text locations, for performing high-level editor functions (eg. "tell me the type of this expression I just highlighted"). Performance of the compiler doesn't seem to be adversely affected. Parsing is still quicker than in 6.0.1, for example. Implementation: This was an excrutiatingly painful change to make: both Simon P.J. and myself have been working on it for the last three weeks or so. The basic changes are: - a new datatype SrcSpan, which represents a beginning and end position in a source file. - To reduce the pain as much as possible, we also defined: data Located e = L SrcSpan e - Every datatype in HsSyn has an equivalent Located version. eg. type LHsExpr id = Located (HsExpr id) and pretty much everywhere we used to use HsExpr we now use LHsExpr. Believe me, we thought about this long and hard, and all the other options were worse :-) Additional changes/cleanups we made at the same time: - The abstract syntax for bindings is now less arcane. MonoBinds and HsBinds with their built-in list constructors have gone away, replaced by HsBindGroup and HsBind (see HsSyn/HsBinds.lhs). - The various HsSyn type synonyms have now gone away (eg. RdrNameHsExpr, RenamedHsExpr, and TypecheckedHsExpr are now HsExpr RdrName, HsExpr Name, and HsExpr Id respectively). - Utilities over HsSyn are now collected in a new module HsUtils. More stuff still needs to be moved in here. - MachChar now has a real Char instead of an Int. All GHC versions that can compile GHC now support 32-bit Chars, so this was a simplification.
-
wolfgang authored
PowerPC Linux support for registerised compilation and native code generation. (object splitting and GHCi are still unsupported). Code for other platforms is not affected, so MERGE TO STABLE.
-
wolfgang authored
PowerPC NCG bugfix: 2-byte data objects should be .short, not .byte MERGE TO STABLE
-
- 09 Dec, 2003 1 commit
-
-
simonmar authored
Add note about -all_load instead of --whole-archive on MacOS X.
-
- 06 Dec, 2003 2 commits
-
-
panne authored
Fixed typo in OpenAL handling.
-
panne authored
Completely overhauled OpenGL/GLUT detection magic, making things more modular. Removed support for Mesa and non-HW-accelerated support on Windoze. Added initial support for handling missing glut.h header on MinGW/MSYS (to be completed). Tested on Cygwin (plain, -mno-cygwin, --without-x), MSYS/MinGW and SuSE 8.2 x86 Linux.
-
- 05 Dec, 2003 1 commit
-
-
stolz authored
Use tso->id instead of tso as index to thread lables (tsos get relocated). Please merge
-
- 02 Dec, 2003 1 commit
-
-
panne authored
Added the first pieces of an OpenAL binding which has been of my disk for quite a while. Note that it is built by default when a usable OpenAL library is found, but this could be disabled via --disable-openal on the configure commandline. Similar behaviour should probably be the default for all optional libraries. Note that I have created a new hierarchy rooted at "Sound", the existing hierarchies didn't fit.
-
- 28 Nov, 2003 2 commits
- 27 Nov, 2003 5 commits
-
-
ross authored
fix typo
-
simonmar authored
Document UNPACK pragma
-
simonmar authored
On reflection, using the '!!' prefix for unboxing a constructor field was a mistake: firstly it has to be written '! !', and secondly it isn't backwards-compatible. So instead, we now use the syntax: data T = T {-# UNPACK #-} !Int to unbox a field. We thought this would be a cute reuse of the UNPACK pragma. The effect of -funbox-strict-fields is to add {-# UNPACK #-} to every strict field.
-
simonmar authored
Fix syntax error
-
simonmar authored
Having tightened up GHC's syntax w.r.t. Haskell 98, it appears that GHC itself was making use of the more lax syntax.
-
- 26 Nov, 2003 2 commits
- 21 Nov, 2003 1 commit
-
-
simonpj authored
Add a note about avoiding trailing spaces in CVSROOT
-
- 18 Nov, 2003 3 commits
- 17 Nov, 2003 13 commits
-
-
simonmar authored
GC dead code and export list entries.
-
simonmar authored
GC dead code.
-
simonmar authored
GC export list.
-
simonmar authored
GC dead code.
-
simonmar authored
GC export list.
-
simonmar authored
GC dead code.
-
simonmar authored
GC export list.
-
simonmar authored
Add an export list; GC dead code.
-
simonmar authored
GC export list.
-
simonmar authored
GC dead code.
-
simonmar authored
GC dead code.
-
simonmar authored
GC dead code.
-
simonmar authored
GC some dead code. In some places, I left useful-looking but currently unused definitions in place, surrounded by #ifdef UNUSED ... #endif.
-
- 16 Nov, 2003 1 commit
-
-
panne authored
* Cleaned up test for GTK_CONFIG * Nuked unused GTK_VERSION
-