docs: function_trait_impl 的注释写错了 (: #34
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Sanitizer | |
on: | |
push: | |
paths: | |
- "inc/**.h" | |
- "inc/**.hpp" | |
- "src/**.c" | |
- "src/**.cpp" | |
- "tests/**.c" | |
- "tests/**.cpp" | |
- "Makefile" | |
- ".github/workflows/sanitizer.yml" | |
pull_request: | |
branches: [master] | |
paths: | |
- "inc/**.h" | |
- "inc/**.hpp" | |
- "src/**.c" | |
- "src/**.cpp" | |
- "tests/**.c" | |
- "tests/**.cpp" | |
- "Makefile" | |
- ".github/workflows/sanitizer.yml" | |
workflow_dispatch: | |
inputs: | |
logLevel: | |
description: "Log level" | |
required: true | |
default: "warning" | |
jobs: | |
sanitizer: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: true | |
matrix: | |
sanitizer: [address, leak, undefined] | |
name: >- | |
Sanitizer ${{ matrix.sanitizer }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
submodules: true | |
# 设置GCC版本 | |
- name: Set up GCC | |
uses: egor-tensin/setup-gcc@v1 | |
with: | |
version: latest | |
# 运行 | |
- name: Test with sanitizer | |
if: ${{ matrix.sanitizer }} != 'none' | |
run: | | |
make test | |
env: | |
MTFMT_BUILD_DEBUG: "1" | |
MTFMT_BUILD_WITH_SANITIZER: "-fsanitize=${{ matrix.sanitizer }}" | |
MTFMT_BUILD_C_DEFS: >- | |
-D_MSTR_USE_MALLOC=1 | |
-D_MSTR_USE_HARDWARE_DIV=1 |