This repository was archived by the owner on May 28, 2025. It is now read-only.
forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit 5c8bff7
Auto merge of rust-lang#101263 - lopopolo:lopopolo/c-unwind-fn-ptr-impls, r=thomcc
Add default trait implementations for "c-unwind" ABI function pointers
Following up on rust-lang#92964, only add default trait implementations for the `c-unwind` family of function pointers. The previous attempt in rust-lang#92964 added trait implementations for many more ABIs and ran into concerns regarding the increase in size of the libcore rlib.
An attempt to abstract away function pointer types behind a unified trait to reduce the duplication of trait impls is being discussed in rust-lang#99531 but this change looks to be blocked on a lang MCP.
Following `@RalfJung's` suggestion in rust-lang#99531 (comment), this commit is another cut at rust-lang#92964 but it _only_ adds the impls for `extern "C-unwind" fn` and `unsafe extern "C-unwind" fn`.
I am interested in landing this patch to unblock the stabilization of the `c_unwind` feature.
RFC: rust-lang/rfcs#2945
Tracking Issue: rust-lang#74990 File tree
3 files changed
+23
-9
lines changed- library/core/src
- ptr
- src/test/ui/issues
3 files changed
+23
-9
lines changedOriginal file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
174 | 174 |
| |
175 | 175 |
| |
176 | 176 |
| |
177 | + | ||
177 | 178 |
| |
178 | 179 |
| |
179 | 180 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1862 | 1862 |
| |
1863 | 1863 |
| |
1864 | 1864 |
| |
1865 | + | ||
1866 | + | ||
1867 | + | ||
1868 | + | ||
1869 | + | ||
1870 | + | ||
1871 | + | ||
1865 | 1872 |
| |
1866 | 1873 |
| |
1867 | - | ||
1874 | + | ||
1868 | 1875 |
| |
1869 | 1876 |
| |
1870 | 1877 |
| |
| |||
1875 | 1882 |
| |
1876 | 1883 |
| |
1877 | 1884 |
| |
1878 | - | ||
1885 | + | ||
1879 | 1886 |
| |
1880 | 1887 |
| |
1881 | 1888 |
| |
1882 | 1889 |
| |
1883 | 1890 |
| |
1884 | - | ||
1891 | + | ||
1885 | 1892 |
| |
1886 | 1893 |
| |
1887 | 1894 |
| |
| |||
1892 | 1899 |
| |
1893 | 1900 |
| |
1894 | 1901 |
| |
1895 | - | ||
1902 | + | ||
1896 | 1903 |
| |
1897 | 1904 |
| |
1898 | 1905 |
| |
| |||
1903 | 1910 |
| |
1904 | 1911 |
| |
1905 | 1912 |
| |
1906 | - | ||
1913 | + | ||
1907 | 1914 |
| |
1908 | 1915 |
| |
1909 | 1916 |
| |
| |||
1913 | 1920 |
| |
1914 | 1921 |
| |
1915 | 1922 |
| |
1916 | - | ||
1923 | + | ||
1917 | 1924 |
| |
1918 | 1925 |
| |
1919 | 1926 |
| |
| |||
1923 | 1930 |
| |
1924 | 1931 |
| |
1925 | 1932 |
| |
1926 | - | ||
1933 | + | ||
1927 | 1934 |
| |
1928 | 1935 |
| |
1929 | 1936 |
| |
| |||
1938 | 1945 |
| |
1939 | 1946 |
| |
1940 | 1947 |
| |
1948 | + | ||
1949 | + | ||
1941 | 1950 |
| |
1942 | 1951 |
| |
1943 | 1952 |
| |
1953 | + | ||
1954 | + | ||
1944 | 1955 |
| |
1945 | 1956 |
| |
1946 | 1957 |
| |
1947 | 1958 |
| |
1948 | 1959 |
| |
1960 | + | ||
1949 | 1961 |
| |
1950 | 1962 |
| |
1963 | + | ||
1951 | 1964 |
| |
1952 | 1965 |
| |
1953 | 1966 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
99 | 99 |
| |
100 | 100 |
| |
101 | 101 |
| |
102 | - | ||
102 | + | ||
103 | 103 |
| |
104 | 104 |
| |
105 | 105 |
| |
| |||
118 | 118 |
| |
119 | 119 |
| |
120 | 120 |
| |
121 | - | ||
121 | + | ||
122 | 122 |
| |
123 | 123 |
| |
124 | 124 |
| |
|
0 commit comments