Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6139991
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T18:03:38+00:00 2026-05-23T18:03:38+00:00

I have a question about Tcl, we are using Tcl to write some test

  • 0

I have a question about Tcl, we are using Tcl to write some test cases for c and c++ application. I saw some Tcl test cases are:

if {0} { #START:HELLO1
//some code here
}#END:HELLO1

if {0} { #START:HELLO2
//some code here
}#END:HELLO2

if {0} { #START:HELLO3
//some code here
}#END:HELLO3

How does these code works? #START: and #END: means what? and why they have index such as:

HELLO1 HELLO2 HELLO3

can anyone help me on this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T18:03:39+00:00Added an answer on May 23, 2026 at 6:03 pm

    Those are very odd looking tests by Tcl terms. If they’d read like this (with the extra semicolon):

    if {0} { #START:HELLO1
    //some code here
    };#END:HELLO1
    

    Then they’d just be blocked out code that does nothing (literally; Tcl won’t attempt to generate code for it, just as a C or C++ compiler is unlikely to do much for if(0){...}) but the version you’ve got is just a syntax error. Braces shouldn’t be followed by anything other than whitespace (unless it is the special {*} syntax, which does expanding substitution).

    That said, I’d expect testing code to look more like this:

    doATest "the test name" {
        // Whatever makes the body of the test, in whatever language
    }
    

    The doATest might ignore the test based on some logic, but the overall script would be oblivious. (Tcl’s own built-in test harness — the tcltest package — follows this pattern with some extra parameters for controlling things like the conditions under which to run the test and the expected result.)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have question about my code which does the Hoare Partition Method. Here is
I have a question about CETP(Common Expect Test Platform), it is a TCL testing
I have a question about using streams in .NET to load files from disk.
I have a question about how to deploy WPF application into a PC without
I have a question about using os.execvp in Python. I have the following bit
I have a question about using new[] . Imagine this: Object.SomeProperty = new[] {string1,
Have a question about the design/usage of asp.net mvc here. In the html helper
I have some question about header files(I'm talking about c, but I think it
I have two question about namespace in Tcl. namespace eval ::dai { set a
I have question about throw. How will the throw work in the following code?

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.