Skip to content

Commit

Permalink
Squashed 'ocaml/' changes from a09392d..c703f5f777
Browse files Browse the repository at this point in the history
c703f5f777 Incorporate upstream comments into type-variable refactor (ocaml#121)
362ba2349f Constrain curry modes to increase along applications (ocaml#108)
b1f0cf9f91 Simplify the extension handling (ocaml#114)
4fd53a1f6f Remove pat_mode from typedtree (ocaml#105)
cf6fcbc129 Handle attributes on lambdas with locally abstract types (ocaml#120)
5fa80fe23f Don't track attributes inside attributes for warning 53 (ocaml#115)
8a69777a3c Handle unclosed `[: ... :]` patterns (via `Generic_array` machinery) (ocaml#117)
b0737f46c4 Add promote-one Makefile target (ocaml#118)
c6ad684608 Refactoring and fixes around module lookup (ocaml#107)
b0a649516b Add documentation for global constructor arguments (ocaml#69)
dd79aeca91 Print `nlocal` in the `-d(raw)lambda` output (ocaml#112)
8035026661 Fix `nlocal` in the generated Lambda for list comprehensions (ocaml#113)
afbcdf0642 Immutable arrays (ocaml#47)
bfe1490dfb fix several issues when removing exp_mode (ocaml#110)
8f46060dc5 Better error message for under-applied functions (ocaml#74)
27331d848d Consistently use Lmutvar or Lvar in comprehensions (ocaml#111)
01e965b549 Skip failing test for now
0131357265 Fix test case to use comprehensions_experimental
22a73684b7 Temporarily disable list comprehensions tests due to locals bug
e08377d2d1 Make `comprehensions` into `comprehensions_experimental` for now (ocaml#109)
947cf892b5 List and array comprehensions (ocaml#46)
bd9e051 remove exp_mode from typedtree (ocaml#100)
a9268d2 Fix misplaced attribute warning when using external parser (and some cleanup) (ocaml#101)
2b33f24 Refactor toplevel local escape check (ocaml#104)
ed2aec6 Comment functions exported from TyVarEnv.
87838ba Move new variable creation into TyVarEnv.
a3f60ab Encapsulate functions that work with tyvars
43d83a6 Prevent possibility of forgetting to re-widen
2f3dd34 Encapsulate context when narrowing type env't
d78ff6d Make immediate64 things mode cross (ocaml#97)
aa25ab9 Fix version number (ocaml#94)
d01ffa0 Fix .depend file (ocaml#93)
942f2ab Bootstrap (ocaml#92)
05f7e38 Check Menhir version (ocaml#91)
1569b58 Move the CI jobs from 4.12 to 4.14. (ocaml#90)

git-subtree-dir: ocaml
git-subtree-split: c703f5f7772dd4252405b086be11c15a3c67f2ac
  • Loading branch information
riaqn committed Feb 23, 2023
1 parent 64caa59 commit bcec5fe
Show file tree
Hide file tree
Showing 176 changed files with 32,458 additions and 10,323 deletions.
170 changes: 134 additions & 36 deletions .depend

Large diffs are not rendered by default.

35 changes: 27 additions & 8 deletions .depend.menhir
Original file line number Diff line number Diff line change
@@ -1,11 +1,30 @@
parsing/parser.cmo : parsing/syntaxerr.cmi parsing/parsetree.cmi \
parsing/longident.cmi parsing/location.cmi parsing/docstrings.cmi \
utils/clflags.cmi parsing/asttypes.cmi parsing/ast_helper.cmi \
parsing/parser.cmo : \
parsing/syntaxerr.cmi \
parsing/parsetree.cmi \
parsing/longident.cmi \
parsing/location.cmi \
parsing/extensions.cmi \
parsing/docstrings.cmi \
utils/clflags.cmi \
parsing/builtin_attributes.cmi \
parsing/asttypes.cmi \
parsing/ast_helper.cmi \
parsing/parser.cmi
parsing/parser.cmx : parsing/syntaxerr.cmx parsing/parsetree.cmi \
parsing/longident.cmx parsing/location.cmx parsing/docstrings.cmx \
utils/clflags.cmx parsing/asttypes.cmi parsing/ast_helper.cmx \
parsing/parser.cmx : \
parsing/syntaxerr.cmx \
parsing/parsetree.cmi \
parsing/longident.cmx \
parsing/location.cmx \
parsing/extensions.cmx \
parsing/docstrings.cmx \
utils/clflags.cmx \
parsing/builtin_attributes.cmx \
parsing/asttypes.cmi \
parsing/ast_helper.cmx \
parsing/parser.cmi
parsing/parser.cmi : parsing/parsetree.cmi parsing/location.cmi \
parsing/parser.cmi : \
parsing/parsetree.cmi \
parsing/longident.cmi \
parsing/location.cmi \
parsing/docstrings.cmi
parsing/parser.ml parsing/parser.mli: parsing/ast_helper.cmi parsing/asttypes.cmi utils/clflags.cmi parsing/docstrings.cmi parsing/location.cmi parsing/longident.cmi parsing/parsetree.cmi parsing/syntaxerr.cmi
parsing/parser.ml parsing/parser.mli: parsing/ast_helper.cmi parsing/asttypes.cmi parsing/builtin_attributes.cmi utils/clflags.cmi parsing/docstrings.cmi parsing/extensions.cmi parsing/location.cmi parsing/longident.cmi parsing/parsetree.cmi parsing/syntaxerr.cmi
38 changes: 19 additions & 19 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,58 +46,58 @@ jobs:
with:
path: 'ocaml-jst'

- name: Cache OCaml 4.12 and dune
- name: Cache OCaml 4.14 and dune
uses: actions/cache@v1
id: cache
with:
path: ${{ github.workspace }}/ocaml-412/_install
key: ${{ matrix.os }}-cache-ocaml-412-dune-341-bits-${{ matrix.boot_cachekey }}
path: ${{ github.workspace }}/ocaml-414/_install
key: ${{ matrix.os }}-cache-ocaml-414-dune-361-bits-${{ matrix.boot_cachekey }}

- name: Checkout OCaml 4.12
- name: Checkout OCaml 4.14
uses: actions/checkout@master
if: steps.cache.outputs.cache-hit != 'true'
with:
repository: 'ocaml/ocaml'
path: 'ocaml-412'
ref: '4.12'
path: 'ocaml-414'
ref: '4.14'

- name: Setup 32-bit C compiler
if: matrix.name == 'i386' && steps.cache.outputs.cache-hit != 'true'
run: |
mkdir -p ocaml-412/_install/bin
{ echo '#!/bin/sh'; echo 'exec gcc -m32 "$@"'; } > ocaml-412/_install/bin/cc32
chmod +x ocaml-412/_install/bin/cc32
mkdir -p ocaml-414/_install/bin
{ echo '#!/bin/sh'; echo 'exec gcc -m32 "$@"'; } > ocaml-414/_install/bin/cc32
chmod +x ocaml-414/_install/bin/cc32
- name: Build OCaml 4.12
- name: Build OCaml 4.14
if: steps.cache.outputs.cache-hit != 'true'
working-directory: ocaml-412
working-directory: ocaml-414
run: |
export PATH=$GITHUB_WORKSPACE/ocaml-412/_install/bin:$PATH
./configure --prefix=$GITHUB_WORKSPACE/ocaml-412/_install ${{ matrix.boot_config }}
export PATH=$GITHUB_WORKSPACE/ocaml-414/_install/bin:$PATH
./configure --prefix=$GITHUB_WORKSPACE/ocaml-414/_install ${{ matrix.boot_config }}
make -j $J world.opt
make install
# Remove unneeded parts to shrink cache file
rm -rf $GITHUB_WORKSPACE/ocaml-412/_install/{lib/ocaml/compiler-libs,lib/ocaml/expunge,bin/*.byte}
rm -rf $GITHUB_WORKSPACE/ocaml-414/_install/{lib/ocaml/compiler-libs,lib/ocaml/expunge,bin/*.byte}
- name: Checkout dune github repo
uses: actions/checkout@master
if: steps.cache.outputs.cache-hit != 'true'
with:
repository: 'ocaml/dune'
ref: '3.4.1'
ref: '3.6.1'
path: 'dune'

- name: Build dune
working-directory: dune
if: steps.cache.outputs.cache-hit != 'true'
run: |
PATH=$GITHUB_WORKSPACE/ocaml-412/_install/bin:$PATH make release
cp dune.exe $GITHUB_WORKSPACE/ocaml-412/_install/bin/dune
PATH=$GITHUB_WORKSPACE/ocaml-414/_install/bin:$PATH make release
cp _boot/dune.exe $GITHUB_WORKSPACE/ocaml-414/_install/bin/dune
- name: Configure OCaml
working-directory: ocaml-jst
run: |
export PATH=$GITHUB_WORKSPACE/ocaml-412/_install/bin:$PATH
export PATH=$GITHUB_WORKSPACE/ocaml-414/_install/bin:$PATH
autoconf
./configure \
--prefix=$GITHUB_WORKSPACE/_install \
Expand All @@ -106,7 +106,7 @@ jobs:
- name: Build, install and test ocaml-jst
working-directory: ocaml-jst
run: |
export PATH=$GITHUB_WORKSPACE/ocaml-412/_install/bin:$PATH
export PATH=$GITHUB_WORKSPACE/ocaml-414/_install/bin:$PATH
make -f Makefile.jst runtest-upstream
env:
BUILD_OCAMLPARAM: ${{ matrix.ocamlparam }}
Expand Down
15 changes: 15 additions & 0 deletions .github/workflows/menhir.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: menhir
on: [push, pull_request]
jobs:
menhir:
name: Check Menhir version
runs-on: ubuntu-latest
steps:
- name: Checkout the ocaml-jst repo
uses: actions/checkout@master
with:
path: 'ocaml-jst'
- name: Check Menhir version
shell: bash
run: |
grep --count --max-count=1 --quiet 'MenhirLib.StaticVersion.require_20210419' ocaml-jst/boot/menhir/parser.ml
10 changes: 9 additions & 1 deletion Makefile.common-jst
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,15 @@ test-one: install_for_test
export LIBRARY_PATH=$$(dirname $$(gfortran -print-file-name=libgfortran.a)); \
fi; \
cd _runtest/testsuite && make one $(if $(TEST),TEST="tests/$(TEST)") $(if $(DIR),DIR="tests/$(DIR)"))


promote-one: install_for_test
(export OCAMLSRCDIR=$$(pwd)/_runtest; \
export CAML_LD_LIBRARY_PATH=$$(pwd)/_runtest/lib/ocaml/stublibs; \
if $$(which gfortran > /dev/null 2>&1); then \
export LIBRARY_PATH=$$(dirname $$(gfortran -print-file-name=libgfortran.a)); \
fi; \
cd _runtest/testsuite && make promote $(if $(TEST),TEST="tests/$(TEST)") $(if $(DIR),DIR="tests/$(DIR)"))

# This target is like a polling version of upstream "make ocamlopt"
.PHONY: hacking
hacking: _build/_bootinstall
Expand Down
4 changes: 2 additions & 2 deletions asmcomp/cmm_helpers.ml
Original file line number Diff line number Diff line change
Expand Up @@ -2347,8 +2347,8 @@ let assignment_kind
(ptr: Lambda.immediate_or_pointer)
(init: Lambda.initialization_or_assignment) =
match init, ptr with
| Assignment Alloc_heap, Pointer -> Caml_modify
| Assignment Alloc_local, Pointer ->
| Assignment Modify_heap, Pointer -> Caml_modify
| Assignment Modify_maybe_stack, Pointer ->
assert Config.stack_allocation;
Caml_modify_local
| Heap_initialization, _ ->
Expand Down
Loading

0 comments on commit bcec5fe

Please sign in to comment.