-
Notifications
You must be signed in to change notification settings - Fork 47
Closed
Description
Hello,
I've not been able to compile the latest release (0.11.2) of this crate on Android. Compilation fails with the following output:
Compiling android_logger v0.11.2
error[E0061]: this function takes 2 arguments but 1 argument was supplied
--> /home/runner/.cargo/registry/src/git.colasdn.top-1ecc6299db9ec823/android_logger-0.11.2/src/lib.rs:295:9
|
295 | Self::new_with_priority(match level {
| _________^^^^^^^^^^^^^^^^^^^^^^^-
296 | | Level::Warn => LogPriority::WARN,
297 | | Level::Info => LogPriority::INFO,
298 | | Level::Debug => LogPriority::DEBUG,
299 | | Level::Error => LogPriority::ERROR,
300 | | Level::Trace => LogPriority::VERBOSE,
301 | | })
| |__________- an argument of type `&CStr` is missing
|
note: associated function defined here
--> /home/runner/.cargo/registry/src/git.colasdn.top-1ecc6299db9ec823/android_logger-0.11.2/src/lib.rs:282:12
|
282 | pub fn new_with_priority(priority: log_ffi::LogPriority, tag: &CStr) -> PlatformLogWriter {
| ^^^^^^^^^^^^^^^^^ ------------------------------ ----------
help: provide the argument
|
295 ~ Self::new_with_priority(match level {
296 + Level::Warn => LogPriority::WARN,
297 + Level::Info => LogPriority::INFO,
298 + Level::Debug => LogPriority::DEBUG,
299 + Level::Error => LogPriority::ERROR,
300 + Level::Trace => LogPriority::VERBOSE,
301 + }, /* &CStr */)
|
As specified in the output, it looks like function new doesn't pass the mandatory tag argument to new_with_priority: https://github.com/Nercury/android_logger-rs/blob/38186ece1056d90b8f75fd2a5eb5c860e0a1704e/src/lib.rs#L281-L302
bryanmehall and danielgranhao
Metadata
Metadata
Assignees
Labels
No labels