-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow leading pipes for type aliases of unions
Summary: Ocaml allows this on pattern matches and it's convenient for larger unions that span one-per-line. This adds support for this to the flow parser: ```javascript type Nodes = | {type: "Identifier", ... } | {type: "Expression", ... } | {type: "Literal", ... } ... ; ``` Note that this adds leading-`|` support for type aliases only for now. We could easily expand to other annotations, but I figured it's most useful for type aliases of large unions -- so might as well start there and leave other things constrained for now. Should be easy to open this up to all annotations in the future if we have a good reason to. Closes #1353 Reviewed By: samwgoldman Differential Revision: D2897790 Pulled By: jeffmo fb-gh-sync-id: edef99adca2876747ea330fa9478b2ed5be36506
- v0.256.0
- v0.255.0
- v0.254.2
- v0.254.1
- v0.254.0
- v0.253.0
- v0.252.0
- v0.251.1
- v0.251.0
- v0.250.0
- v0.249.0
- v0.248.1
- v0.248.0
- v0.247.1
- v0.247.0
- v0.246.0
- v0.245.2
- v0.245.1
- v0.245.0
- v0.244.0
- v0.243.0
- v0.242.1
- v0.242.0
- v0.241.0
- v0.240.0
- v0.239.1
- v0.239.0
- v0.238.3
- v0.238.2
- v0.238.1
- v0.238.0
- v0.237.2
- v0.237.1
- v0.237.0
- v0.236.0
- v0.235.1
- v0.234.0
- v0.233.0
- v0.232.0
- v0.231.0
- v0.230.0
- v0.229.2
- v0.229.1
- v0.229.0
- v0.228.0
- v0.227.0
- v0.226.0
- v0.225.1
- v0.225.0
- v0.224.0
- v0.223.3
- v0.223.2
- v0.223.0
- v0.222.0
- v0.221.0
- v0.220.1
- v0.220.0
- v0.219.5
- v0.219.4
- v0.219.3
- v0.219.2
- v0.219.0
- v0.218.1
- v0.218.0
- v0.217.2
- v0.217.1
- v0.217.0
- v0.216.1
- v0.216.0
- v0.215.1
- v0.215.0
- v0.214.0
- v0.213.1
- v0.213.0
- v0.212.0
- v0.211.1
- v0.211.0
- v0.210.2
- v0.210.1
- v0.210.0
- v0.209.1
- v0.209.0
- v0.208.1
- v0.208.0
- v0.207.0
- v0.206.0
- v0.205.1
- v0.205.0
- v0.204.1
- v0.204.0
- v0.203.1
- v0.203.0
- v0.202.1
- v0.202.0
- v0.201.0
- v0.200.1
- v0.200.0
- v0.199.1
- v0.199.0
- v0.198.2
- v0.198.1
- v0.198.0
- v0.197.0
- v0.196.3
- v0.196.2
- v0.196.1
- v0.196.0
- v0.195.2
- v0.195.1
- v0.195.0
- v0.194.0
- v0.193.0
- v0.192.0
- v0.191.0
- v0.190.1
- v0.190.0
- v0.189.0
- v0.188.2
- v0.188.1
- v0.188.0
- v0.187.1
- v0.187.0
- v0.186.0
- v0.185.2
- v0.185.1
- v0.185.0
- v0.184.0
- v0.183.1
- v0.183.0
- v0.182.0
- v0.181.2
- v0.181.1
- v0.181.0
- v0.180.1
- v0.180.0
- v0.179.0
- v0.178.1
- v0.178.0
- v0.177.0
- v0.176.3
- v0.176.2
- v0.176.1
- v0.176.0
- v0.175.1
- v0.175.0
- v0.174.1
- v0.174.0
- v0.173.0
- v0.172.0
- v0.171.0
- v0.170.0
- v0.169.0
- v0.168.0
- v0.167.1
- v0.167.0
- v0.166.1
- v0.166.0
- v0.165.1
- v0.165.0
- v0.164.0
- v0.163.0
- v0.162.1
- v0.162.0
- v0.161.0
- v0.160.2
- v0.160.1
- v0.160.0
- v0.159.0
- v0.158.0
- v0.157.0
- v0.156.0
- v0.155.1
- v0.155.0
- v0.154.0
- v0.153.0
- v0.152.0
- v0.151.0
- v0.150.1
- v0.150.0
- v0.149.0
- v0.148.0
- v0.147.0
- v0.146.0
- v0.145.0
- v0.144.0
- v0.143.1
- v0.143.0
- v0.142.0
- v0.141.0
- v0.140.0
- v0.139.0
- v0.138.0
- v0.137.0
- v0.136.0
- v0.135.0
- v0.134.0
- v0.133.0
- v0.132.0
- v0.131.0
- v0.130.0
- v0.129.0
- v0.128.0
- v0.127.0
- v0.126.1
- v0.126.0
- v0.125.1
- v0.125.0
- v0.124.0
- v0.123.0
- v0.122.0
- v0.121.0
- v0.120.1
- v0.120.0
- v0.119.1
- v0.119.0
- v0.118.0
- v0.117.1
- v0.117.0
- v0.116.1
- v0.116.0
- v0.115.0
- v0.114.0
- v0.113.0
- v0.112.0
- v0.111.3
- v0.111.2
- v0.111.1
- v0.111.0
- v0.110.1
- v0.110.0
- v0.109.0
- v0.108.0
- v0.107.0
- v0.106.3
- v0.106.2
- v0.106.1
- v0.106.0
- v0.105.2
- v0.105.0
- v0.104.0
- v0.103.0
- v0.102.0
- v0.102.0-rc
- v0.101.1
- v0.101.0
- v0.100.0
- v0.99.1
- v0.99.0
- v0.98.1
- v0.98.0
- v0.97.0
- v0.96.1
- v0.96.0
- v0.95.2
- v0.95.1
- v0.95.0
- v0.94.0
- v0.93.0
- v0.92.1
- v0.92.0
- v0.91.0
- v0.90.0
- v0.89.0
- v0.88.0
- v0.87.0
- v0.86.0
- v0.85.0
- v0.84.0
- v0.83.0
- v0.82.0
- v0.81.0
- v0.80.0
- v0.79.1
- v0.79.0
- v0.78.0
- v0.77.0
- v0.76.0
- v0.75.0
- v0.74.0
- v0.73.0
- v0.72.0
- v0.71.0
- v0.70.0
- v0.69.0
- v0.68.0
- v0.67.1
- v0.67.0
- v0.66.0
- v0.65.0
- v0.64.0
- v0.63.1
- v0.63.0
- v0.62.0
- v0.61.0
- v0.60.1
- v0.60.0
- v0.59.0
- v0.58.0
- v0.57.3
- v0.57.2
- v0.57.1
- v0.57.0
- v0.56.0
- v0.55.0
- v0.54.1
- v0.54.0
- v0.53.1
- v0.53.0
- v0.52.0
- v0.51.1
- v0.51.0
- v0.50.0
- v0.49.1
- v0.49.0
- v0.48.0
- v0.47.0
- v0.46.0
- v0.45.0
- v0.44.1
- v0.44.0
- v0.43.1
- v0.43.0
- v0.42.0
- v0.41.0
- v0.40.0
- v0.39.0
- v0.38.0
- v0.37.4
- v0.37.3
- v0.37.2
- v0.37.1
- v0.37.0
- v0.36.0
- v0.35.0
- v0.34.0
- v0.33.0
- v0.32.0
- v0.31.0
- v0.30.0
- v0.29.0
- v0.28.0
- v0.27.0
- v0.26.0
- v0.25.0
- v0.24.2
- v0.24.1
- v0.24.0
- v0.23.1
- v0.23.0
- v0.22.1
- v0.22.0
Showing
2 changed files
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters