Skip to content

Commit 769ac67

Browse files
committed
record_renaming support
1 parent fe983ed commit 769ac67

23 files changed

+19162
-18984
lines changed

jscomp/common/bs_version.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
* You should have received a copy of the GNU Lesser General Public License
2323
* along with this program; if not, write to the Free Software
2424
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *)
25-
let version = "6.3.0-dev.1"
25+
let version = "7.0.0-dev.2"
2626
let header =
2727
"// Generated by BUCKLESCRIPT, PLEASE EDIT WITH CARE"
2828
let package_name = "bs-platform"

jscomp/core/js_dump.ml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -811,8 +811,9 @@ and expression_desc cxt ~(level:int) f x : cxt =
811811
(Ext_list.map_combine fields el Ext_ident.convert)))
812812
| Caml_block(el,_, _, Blk_record fields) ->
813813
expression_desc cxt ~level f (Object (
814-
(Ext_list.map_combine (Array.to_list fields) el Ext_ident.convert)))
815-
(*FIXME: avoid allocaton *)
814+
(List.combine (Array.to_list fields) el )))
815+
(* name convention of Record is slight different from modules
816+
*)
816817
| Caml_block( el, mutable_flag, tag, tag_info)
817818
->
818819
(* Note that, if we ignore more than tag [0] we loose some information

jscomp/core/js_exp_make.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -397,7 +397,7 @@ let array_index_by_int ?comment (e : t) (pos : int32) : t =
397397
| _ -> { expression_desc = Array_index (e, int ?comment pos); comment = None}
398398

399399
let record_access (e : t) (name : string) (pos : int32) =
400-
let name = Ext_ident.convert name in
400+
(* let name = Ext_ident.convert name in *)
401401
match e.expression_desc with
402402
| Array (l,_) (* Float i -- should not appear here *)
403403
| Caml_block (l,_, _, _) when no_side_effect e

0 commit comments

Comments
 (0)