José Valim
cb2e03688e
Perform return type inference and application across local calls ( #13984 )
2024-11-11 23:06:31 +01:00
José Valim
485ca72ae2
Infer types and use them across remote calls ( #13981 )
...
This also unifies handling of deterministic builds with Erlang/OTP
as well as warnings_as_errors.
2024-11-09 18:00:27 +01:00
José Valim
9d1933b679
Use attributes field to compute behaviours
2024-11-08 12:33:08 +01:00
José Valim
57de6ea33a
Type behaviour_info, module_info, and __info__
2024-11-08 12:33:08 +01:00
Waseem Medhat
f18343d8c6
Fix typo in Access.get_and_update/3 error message ( #13979 )
2024-11-07 22:25:46 +01:00
José Valim
f44aa8d710
Allow aliases and imports to be enabled conditionally in module body, closes #13975
2024-11-07 17:09:44 +01:00
José Valim
731e714b6f
Define fewer modules in aliases tests
2024-11-07 13:45:11 +01:00
José Valim
3146c4a71a
Simplify metadata stored in ExCk chunk
...
The checker only runs on functions, so there is no need
to store macros. This reduces the amount of data serialized
and stored. In Livebook, it makes the group pass run about
30% faster.
2024-11-07 13:32:43 +01:00
José Valim
baf77f1cbf
Update to set-theoretic docs
2024-11-07 11:59:04 +01:00
Jonatan Kłosko
5b221a5545
Add AST metadata about assoc operator location ( #13978 )
2024-11-07 10:14:38 +01:00
José Valim
9197ce51fc
Handle precedence in =
2024-11-07 08:48:21 +01:00
José Valim
0e052fd18e
Remove unused :match_var tuple
2024-11-06 16:30:55 +01:00
Jonatan Kłosko
7d421b197c
Add parens meta to stab operator and empty block ( #13973 )
2024-11-06 13:55:04 +01:00
José Valim
c3dc6c86dd
Detect never matching clauses and patterns ( #13968 )
2024-11-06 13:51:04 +01:00
Tobias Pfeiffer
e28a84ce2a
Fix bug with schemaless URI in URI.merge/2 ( #13970 )
...
Only occurs when mixing strings and URIs, but the docs seem to
encourage that.
Without the fix the test results in the following error:
```
1) test merge/2 (URITest)
test/elixir/uri_test.exs:376
** (KeyError) key :scheme not found in: "http://google.com/foo "
If you are using the dot syntax, such as map.field, make sure the left-hand side of the dot is a map
code: assert URI.merge("http://google.com/foo ", URI.new!("//example.com/baz"))
stacktrace:
(elixir 1.18.0-dev) lib/uri.ex:911: URI.merge/2
test/elixir/uri_test.exs:390: (test)
```
That's because that (one) particular clause didn't check for the
base to be a `%URI{}`.
2024-11-06 12:35:32 +01:00
José Valim
01474e0cd4
Type checking of try
2024-11-05 19:08:18 +01:00
Jonatan Kłosko
d0f7c03744
Fix delimiter metadata for single quote atoms and remote calls ( #13966 )
2024-11-05 17:11:39 +01:00
Jonatan Kłosko
ee90126527
Add delimiter meta to demote calls with quoted identifier ( #13963 )
2024-11-05 13:14:20 +01:00
José Valim
1ca06361b6
Type checking of stacktrace and error/raise functions
2024-11-05 13:13:59 +01:00
José Valim
3e9fb4d5ad
Type checking of case and receive
2024-11-05 13:13:59 +01:00
José Valim
2b687fe733
Type map and struct updates ( #13957 )
2024-11-05 11:46:55 +01:00
Guillaume Duboc
7abcb484f8
Add tuple_values to descr ( #13964 )
2024-11-05 11:38:48 +01:00
José Valim
7e1aaacf53
Add more tests around list hd/tl
2024-11-04 16:58:31 +01:00
Jonatan Kłosko
e54b87c181
Fix formatter adding extra escapes to remote call functions ( #13960 )
2024-11-04 14:37:46 +01:00
José Valim
ef56e81d34
Improve coverage over union calls
2024-11-04 14:36:53 +01:00
José Valim
1557d1db5f
Typecheck cond
2024-11-04 14:36:53 +01:00
Jean Klingler
5d626cb873
Improve validation of unquote_splicing AST ( #13961 )
2024-11-04 22:08:48 +09:00
José Valim
9bf8233f68
Improve error messages for bad funs
2024-11-04 09:31:09 +01:00
José Valim
ae396c109b
Type timeouts in receive
2024-11-04 09:25:15 +01:00
José Valim
9f182f9abd
No longer automatically tag structs as dynamic
2024-11-03 16:05:23 +01:00
Jonatan Kłosko
bd7d428ca0
Add metadata about single-expression block closing/opening ( #13940 )
2024-11-03 10:20:44 +01:00
Jean Klingler
322159cc7f
Add test for call with thai atom ( #13952 )
2024-11-03 17:26:35 +09:00
Jean Klingler
cc68ad91cb
Add shallow validation when unquoting AST ( #13950 )
2024-11-03 17:20:33 +09:00
José Valim
e3f017d0b2
Deal with lists inside tuples inside lists
2024-11-01 21:46:43 +01:00
José Valim
69a95a8e8c
Merge empty_list and non_empty_list together on pretty printing
2024-11-01 21:03:27 +01:00
José Valim
4dd0d5d86e
Spread pattern info namespace over positive and negative keys
2024-11-01 20:53:12 +01:00
José Valim
dfa733314d
Properly track patterns nested in lists
2024-11-01 20:49:41 +01:00
José Valim
aa3d2357f3
Add guards to typespec translation, closes #13948
2024-11-01 17:27:46 +01:00
José Valim
c90bd0fca5
Ensure all variables are propagated in a bad match, closes #13946
2024-11-01 17:21:32 +01:00
José Valim
f2d8064121
Do not halt streams twice in Stream.transform/5, closes #13944
2024-10-31 16:42:55 +01:00
José Valim
4a97256839
Remove uneeded blank line
2024-10-31 15:20:45 +01:00
José Valim
8ad110aba0
Clarify bang convention
2024-10-31 15:16:10 +01:00
André Albuquerque
8f594a3b0a
Fix typo in anti-pattern docs ( #13943 )
2024-10-31 11:15:57 +01:00
Wojtek Mach
f9eda1c382
Update "Structs with 32 fields or more" anti pattern ( #13942 )
2024-10-31 11:05:58 +01:00
José Valim
af953c15b2
Add anti-pattern on struct with 32 fields or more
2024-10-31 10:32:11 +01:00
José Valim
705407b61a
Share profiling code in ParallelCompiler
2024-10-30 20:05:34 +01:00
André Albuquerque
63aa5703de
Measure each_cycle callback + deadlock detection ( #13941 )
2024-10-30 19:45:32 +01:00
José Valim
91e76d311c
Keep compatibility with modules from archives
2024-10-30 19:38:39 +01:00
José Valim
8c78a0ea9c
Mark defguard expansion outside of guards as generated
2024-10-30 10:32:30 +01:00
José Valim
e6857d5af3
Store record metadata in the documentation chunk ( #13939 )
2024-10-30 09:24:58 +01:00