Changeset 15443 for src/Pugs/Meta

Show
Ignore:
Timestamp:
03/04/07 14:47:38 (21 months ago)
Author:
audreyt
Message:

* Try making old-land Val Typeable in a -boot file

to avoid most of the circularity. This may not work in 6.6 -- needs test.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • src/Pugs/Meta/Perl5.hs

    r15441 r15443  
    88import Data.Typeable (Typeable) 
    99import qualified Data.Map as Map 
    10 import {-# SOURCE #-} Pugs.AST.Internals (envContext, anyToVal) 
     10import {-# SOURCE #-} Pugs.AST.Internals (envContext, anyToVal, anyFromVal) 
    1111import Pugs.Types 
    1212 
     
    2626        | Just x' <- fromTypeable x = liftIO . vintToSV $ (cast :: PureInt -> Integer)    x' 
    2727        | Just x' <- fromTypeable x = liftIO . vnumToSV $ (cast :: PureNum -> Double)     x' 
     28        | Just x' <- fromTypeable x = anyFromVal x' 
    2829        | otherwise                 = fail $ "Cannot coerce to SV: " ++ show (typeOf x) 
    2930