File tree Expand file tree Collapse file tree 7 files changed +19
-17
lines changed Expand file tree Collapse file tree 7 files changed +19
-17
lines changed Original file line number Diff line number Diff line change 11{
22  "parserOptions" : {
3-     "ecmaVersion" : 5 
3+     "ecmaVersion" : 6 ,
4+     "sourceType" : " module" 
45  },
56  "extends" : " eslint:recommended" 
6-   "env" : {
7-     "commonjs" : true 
8-   },
97  "rules" : {
108    "strict" : [2 , " global" 
119    "block-scoped-var" : 2 ,
Original file line number Diff line number Diff line change 1313      - uses : actions/checkout@v2 
1414
1515      - uses : purescript-contrib/setup-purescript@main 
16+         with :
17+           purescript : " unstable" 
1618
1719      - uses : actions/setup-node@v1 
1820        with :
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ Notable changes to this project are documented in this file. The format is based
55## [ Unreleased]  
66
77Breaking changes:
8+ -  Migrate FFI to ES modules (#39   by @kl0tl   and @JordanMartinez  )
89
910New features:
1011
Original file line number Diff line number Diff line change 1616    " package.json" 
1717  ],
1818  "dependencies" : {
19-     "purescript-effect" : " ^3.0.0 " 
20-     "purescript-prelude" : " ^5.0.0 " 
19+     "purescript-effect" : " master " 
20+     "purescript-prelude" : " master " 
2121  },
2222  "devDependencies" : {
23-     "purescript-assert" : " ^5.0.0 " 
23+     "purescript-assert" : " master " 
2424  }
2525}
Original file line number Diff line number Diff line change 77  },
88  "devDependencies" : {
99    "eslint" : " ^7.15.0" 
10-     "pulp" : " ^15 .0.0" 
11-     "purescript-psa" : " ^0.8.0 " 
10+     "pulp" : " 16 .0.0- 0" 
11+     "purescript-psa" : " ^0.8.2 " 
1212    "rimraf" : " ^3.0.2" 
1313  }
1414}
Original file line number Diff line number Diff line change 1- "use strict" ; 
2- 
3- exports . new  =  function  ( val )  { 
1+ export  const  _new  =  function  ( val )  { 
42  return  function  ( )  { 
53    return  {  value : val  } ; 
64  } ; 
75} ; 
86
9- exports . newWithSelf  =  function  ( f )  { 
7+ export   const   newWithSelf  =  function  ( f )  { 
108  return  function  ( )  { 
119    var  ref  =  {  value : null  } ; 
1210    ref . value  =  f ( ref ) ; 
1311    return  ref ; 
1412  } ; 
1513} ; 
1614
17- exports . read  =  function  ( ref )  { 
15+ export   const   read  =  function  ( ref )  { 
1816  return  function  ( )  { 
1917    return  ref . value ; 
2018  } ; 
2119} ; 
2220
23- exports . modifyImpl  =  function  ( f )  { 
21+ export   const   modifyImpl  =  function  ( f )  { 
2422  return  function  ( ref )  { 
2523    return  function  ( )  { 
2624      var  t  =  f ( ref . value ) ; 
@@ -30,7 +28,7 @@ exports.modifyImpl = function (f) {
3028  } ; 
3129} ; 
3230
33- exports . write  =  function  ( val )  { 
31+ export   const   write  =  function  ( val )  { 
3432  return  function  ( ref )  { 
3533    return  function  ( )  { 
3634      ref . value  =  val ; 
Original file line number Diff line number Diff line change @@ -41,7 +41,10 @@ foreign import data Ref :: Type -> Type
4141type  role  Ref  representational 
4242
4343--  | Create a new mutable reference containing the specified value.
44- foreign  import  new  ::  forall  s . s  ->  Effect  (Ref  s )
44+ foreign  import  _new  ::  forall  s . s  ->  Effect  (Ref  s )
45+ 
46+ new  ::  forall  s . s  ->  Effect  (Ref  s )
47+ new = _new
4548
4649--  | Create a new mutable reference containing a value that can refer to the
4750--  | `Ref` being created.
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments