Skip to content

Commit

Permalink
fix misspelling
Browse files Browse the repository at this point in the history
  • Loading branch information
xianjimli committed Nov 18, 2024
1 parent 0bfb542 commit e115dc9
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions docs/changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

2024/11/18
* 完善 atomic(感谢兆坤提供补丁)
* 修复拼写错误(感谢兆坤提供补丁)

2024/11/17
* 完善 TK_STRINGIZE(感谢兆坤提供补丁)
Expand Down
6 changes: 3 additions & 3 deletions src/tkc/atomic.h
Original file line number Diff line number Diff line change
Expand Up @@ -713,13 +713,13 @@ static ret_t tk_atomic_fetch_sub(tk_atomic_t* atomic, value_t* v) {
}
#else
/* 不支持原子操作,已退化为互斥锁,编译时请指定C11以上的C语言标准,以确保支持原子操作! */
#pragma message(__FILE__ "(" TK_SRTINGIZE( \
#pragma message(__FILE__ "(" TK_STRINGIZE( \
__LINE__) "): " \
"Warning : Atomic operation is not supported and have degenerated into mutex, please specify the C language standard above C11 when compiling to ensure that atomic operation is supported!")
#ifdef __cplusplus
#pragma message("__cplusplus = " TK_SRTINGIZE(__cplusplus))
#pragma message("__cplusplus = " TK_STRINGIZE(__cplusplus))
#else
#pragma message("__STDC_VERSION__ = " TK_SRTINGIZE(__STDC_VERSION__))
#pragma message("__STDC_VERSION__ = " TK_STRINGIZE(__STDC_VERSION__))
#endif /* __cplusplus */
#ifdef __STDC_NO_ATOMICS__
#pragma message("__STDC_NO_ATOMICS__ = TRUE")
Expand Down
2 changes: 1 addition & 1 deletion src/tkc/types_def.h
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ typedef int socklen_t;
#endif /*FALSE*/

#define _TK_STRINGIZE_(symbol) #symbol
#define TK_SRTINGIZE(macro) _TK_STRINGIZE_(macro)
#define TK_STRINGIZE(macro) _TK_STRINGIZE_(macro)

#if defined(__GNUC__) && !defined(__cplusplus)
typedef _Bool bool_t;
Expand Down

0 comments on commit e115dc9

Please sign in to comment.