mirror of
https://github.com/openharmony/third_party_rust_libloading.git
synced 2026-07-19 13:16:19 -04:00
Made documentation spelling consistent
It was previously a mix of British and American English, it is now just British English
This commit is contained in:
@@ -7,7 +7,7 @@ use std::os::raw::c_int;
|
||||
/// Specifying `RTLD_LAZY` should improve performance on implementations supporting dynamic
|
||||
/// symbol binding since a process might not reference all of the symbols in an executable
|
||||
/// object file. And, for systems supporting dynamic symbol resolution for normal process
|
||||
/// execution, this behavior mimics the normal handling of process execution.
|
||||
/// execution, this behaviour mimics the normal handling of process execution.
|
||||
///
|
||||
/// Conflicts with [`RTLD_NOW`].
|
||||
///
|
||||
@@ -18,7 +18,7 @@ pub const RTLD_LAZY: c_int = posix::RTLD_LAZY;
|
||||
///
|
||||
/// All necessary relocations shall be performed when the executable object file is first
|
||||
/// loaded. This may waste some processing if relocations are performed for symbols
|
||||
/// that are never referenced. This behavior may be useful for applications that need to
|
||||
/// that are never referenced. This behaviour may be useful for applications that need to
|
||||
/// know that all symbols referenced during execution will be available before
|
||||
/// [`Library::open`] returns.
|
||||
///
|
||||
|
||||
+1
-1
@@ -142,7 +142,7 @@ impl Library {
|
||||
pub fn this() -> Library {
|
||||
unsafe {
|
||||
// SAFE: this does not load any new shared library images, no danger in it executing
|
||||
// initializer routines.
|
||||
// initialiser routines.
|
||||
Library::open(None::<&OsStr>, RTLD_LAZY | RTLD_LOCAL).expect("this should never fail")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -452,7 +452,7 @@ pub const LOAD_LIBRARY_AS_DATAFILE_EXCLUSIVE: DWORD = consts::LOAD_LIBRARY_AS_DA
|
||||
|
||||
/// Map the file into the process’ virtual address space as an image file.
|
||||
///
|
||||
/// The loader does not load the static imports or perform the other usual initialization steps.
|
||||
/// The loader does not load the static imports or perform the other usual initialisation steps.
|
||||
/// Use this flag when you want to load a DLL only to extract messages or resources from it.
|
||||
///
|
||||
/// Unless the application depends on the file having the in-memory layout of an image, this value
|
||||
@@ -513,7 +513,7 @@ pub const LOAD_LIBRARY_SEARCH_USER_DIRS: DWORD = consts::LOAD_LIBRARY_SEARCH_USE
|
||||
/// discussed in the [Remarks section] to find associated executable modules that the specified
|
||||
/// module causes to be loaded.
|
||||
///
|
||||
/// If this value is used and `filename` specifies a relative path, the behavior is undefined.
|
||||
/// If this value is used and `filename` specifies a relative path, the behaviour is undefined.
|
||||
///
|
||||
/// If this value is not used, or if `filename` does not specify a path, the system uses the
|
||||
/// standard search strategy discussed in the [Remarks section] to find associated executable
|
||||
|
||||
+2
-2
@@ -148,7 +148,7 @@ fn test_static_ptr() {
|
||||
}
|
||||
|
||||
#[test]
|
||||
// Something about i686-pc-windows-gnu, makes dll initialization code call abort when it is loaded
|
||||
// Something about i686-pc-windows-gnu, makes dll initialisation code call abort when it is loaded
|
||||
// and unloaded many times. So far it seems like an issue with mingw, not libloading, so ignoring
|
||||
// the target. Especially since it is very unlikely to be fixed given the state of support its
|
||||
// support.
|
||||
@@ -193,7 +193,7 @@ fn library_this() {
|
||||
use libloading::os::windows::Library;
|
||||
make_helpers();
|
||||
unsafe {
|
||||
// SAFE: well-known library without initializers is loaded.
|
||||
// SAFE: well-known library without initialisers is loaded.
|
||||
let _lib = Library::new(LIBPATH).unwrap();
|
||||
let this = Library::this().expect("this library");
|
||||
// SAFE: functions are never called.
|
||||
|
||||
Reference in New Issue
Block a user