Logo
Explore Help
Register Sign In
rust-lang/rust
1
0
Fork 0
You've already forked rust
Code Issues Pull Requests Actions 1 Packages Projects Releases Wiki Activity
Files
359bfa901b9d8eddbed7b88b6716dbb77b7bfb95
rust/tests/ui/box/alloc-unstable-fail.rs

7 lines
143 B
Rust
Raw Normal View History

Support custom allocators in `Box` Remove `Box::leak_with_alloc` Add leak-test for box with allocator Rename `AllocErr` to `AllocError` in leak-test Add `Box::alloc` and adjust examples to use the new API
2020-10-06 16:37:23 +02:00
use std::boxed::Box;
fn main() {
let _boxed: Box<u32, _> = Box::new(10);
use backticks instead of single quotes when reporting "use of unstable library feature" This is consistent with all other diagnostics I could find containing features and enables the use of `DiagSymbolList` for generalizing diagnostics for unstable library features to multiple features.
2024-11-02 16:10:24 -07:00
//~^ ERROR use of unstable library feature `allocator_api`
Support custom allocators in `Box` Remove `Box::leak_with_alloc` Add leak-test for box with allocator Rename `AllocErr` to `AllocError` in leak-test Add `Box::alloc` and adjust examples to use the new API
2020-10-06 16:37:23 +02:00
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.6 Page: 1782ms Template: 3ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API