You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@trafficserver.apache.org by GitBox <gi...@apache.org> on 2022/05/02 00:10:24 UTC

[GitHub] [trafficserver] maskit commented on a diff in pull request #8809: Change HttpSM.cc from using Debug() to new interface, Dbg().

maskit commented on code in PR #8809:
URL: https://github.com/apache/trafficserver/pull/8809#discussion_r862541220


##########
proxy/http/HttpSM.cc:
##########
@@ -273,7 +370,7 @@ HttpVCTable::cleanup_all()
 #define STATE_ENTER(state_name, event)                                                 \
   {                                                                                    \
     /*ink_assert (magic == HTTP_SM_MAGIC_ALIVE); */ REMEMBER(event, reentrancy_count); \
-    SMDebug("http", "[%s, %s]", #state_name, HttpDebugNames::get_event_name(event));   \
+    SMDebugHttp("[%s, %s]", #state_name, HttpDebugNames::get_event_name(event));       \

Review Comment:
   > If all debug tags were valid C++ identifiers...
   
   I like the concatenation/stringization macro idea. It would be confusing a little since old Debug() requires quotations though, I prefer it rather than other naming patterns.
   
   Also, somebody told me that he prefer to have "Debug" at the end of macro names because that enables you to find (grep) Debug lines easily, when I added macros for HTTP/2 or 3.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org