Crates.io | marker_adapter |
lib.rs | marker_adapter |
version | 0.5.0 |
source | src |
created_at | 2022-11-04 10:36:15.675513 |
updated_at | 2023-12-28 21:03:28.846444 |
description | Marker's adapter for common functions shared among lint drivers |
homepage | |
repository | https://github.com/rust-marker/marker |
max_upload_size | |
id | 705006 |
size | 62,518 |
This crate provides a common interface for drivers to communicate with lint crates for Marker. It does some heavy lifting which would otherwise need to be done by each individual driver. You're welcome to check out Marker's Readme if you're interested in the project.
Warning
This crate is not part of Marker's official API, it's only intended to be used by drivers.
The adapter can load a list of lint crates and send information from the driver to all lint crates. The adapter and API takes care of safe ABI communication between the driver and lint crates.
Marker's API requires some callbacks from the lint crates into the driver. The adapter can deal with all the ABI conversions, drivers only need to implement the DriverContext
trait provided by the adapter.
An adapter instance can be created from the environment. For this, the following environment values are read:
MARKER_LINT_CRATES
: A semicolon separated list of crate name and absolute path pairs. Each pair is internally separated by a colon.Contributions are highly appreciated! If you encounter any issues or have suggestions for improvements, please check out Marker's GitHub repository.
Copyright (c) 2022-2023 Rust-Marker
Rust-marker is distributed under the terms of the MIT license or the Apache License (Version 2.0).
See LICENSE-APACHE, LICENSE-MIT.