skip to main content
10.1145/2676723.2677281acmconferencesArticle/Chapter ViewAbstractPublication PagessigcseConference Proceedingsconference-collections
research-article

Looking Glass: A C++ Library for Testing Student Programs through Reflection

Published:24 February 2015Publication History

ABSTRACT

Looking Glass (https://github.com/sturner84/LookingGlass) is a library designed to support the testing of students' C++ code through reflection. Instructors can design tests that compile even if there are mismatches between the instructor's and student's code (like misspelled function names or parameters that do not have the expected types). Using the automatically generated metadata, instructors can search for and call functions or methods in the student code, including the main function, while providing feedback (rather than a compile error) if the required code is not found. Although not suitable for all C++ programs, Looking Glass was designed to support instructors in introductory and intermediate classes and to be transparent to the students.

References

  1. Boost. http://www.boost.org/. Accessed 9/2/2014.Google ScholarGoogle Scholar
  2. Brown, P.J. 1983. Error messages: the neglected area of the man/machine interface. Commun. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Chochlík, M. Mirror. http://kifri.fri.uniza.sk/~chochlik/ mirror-lib/html/index.html. Accessed 9/1/2014.Google ScholarGoogle Scholar
  4. Devadithya, T. et al. 2007. C++ reflection for high performance problem solving environments. Proceedings of the 2007 spring simulation multiconference - Volume 2 (Norfolk, Virginia, 2007), 435--440. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Devadithya, T. et al. XCppRefl - C++ Reflection Library. http://www.extreme.indiana.edu/reflcpp/. Accessed 9/1/14.Google ScholarGoogle Scholar
  6. Doxygen. http://www.stack.nl/~dimitri/doxygen/index.html. Accessed 9/2/2014.Google ScholarGoogle Scholar
  7. Edwards, S.H. Web-CAT. http://web-cat.cs.vt.edu/. Accessed 9/1/2014.Google ScholarGoogle Scholar
  8. Edwards, S.H. and Perez-Quinones, M.A. 2007. Experiences using test-driven development with an automated grader. J. Comput. Small Coll. 22, 3 (2007), 44--50. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Marceau, G. et al. 2011. Mind your language: on novices? interactions with error messages. Proceedings of the 10th SIGPLAN symposium on New ideas, new paradigms, and reflections on programming and software (Portland, Oregon, USA, 2011), 3--18. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Nienaltowski, M.-H. et al. 2008. Compiler error messages: what can help novices? Proceedings of the 39th SIGCSE technical symposium on Computer science education (Portland, OR, USA, 2008), 168--172. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Nordquist, P. 2007. Providing accurate and timely feedback by automatically grading student programming labs. J. Comput. Sci. Coll. 23, 2 (2007), 16--23. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Shams, Z. and Edwards, S.H. 2013. Reflection Support: Java Reflection Made Easy. The Open Software Engineering Journal. 7, (2013).Google ScholarGoogle Scholar
  13. Wang, Q. cpgf. http://cpgf.org/. Accessed: 9/1/2014.Google ScholarGoogle Scholar

Index Terms

  1. Looking Glass: A C++ Library for Testing Student Programs through Reflection

    Recommendations

    Reviews

    Marlin W Thomas

    Computer-assisted evaluation of computer code is a work in progress. This paper on a library that tests students' C++ programs shows both the progress made and the work remaining. The paper substantiates the benefit that students would derive from computer-assisted assessment, describes a solution, outlines its limitations, and suggests future work. It opens with an overview of the problems associated with evaluating student submissions in C++: opaqueness of error messages and difficulty compiling student code against instructor code. To supplement this analysis, the author presents the results of an empirical study that indicates that students would benefit from a better handling of these problems. He also sets a goal for computer-aided assessment: the graceful handling of the mismatch between student and instructor code. The proposed solution, Looking Glass, is a C++ library that uses reflection-determining at runtime what classes, methods, and variables are in the program and gaining access to their values-implemented through an open-source library. It is powerful enough to examine nearly all structures in C++. Unions and templates are notable exceptions. All of its functionality is transparent to the student, but there is some overhead for the instructor. The empirical study indicates that it achieved the primary goal of reflecting the code most frequently used in introductory and intermediate courses in C++, but it only partially met the secondary goal of providing streamlined syntax and ease of setup. The paper ends by suggesting future work such as improving integration with other tools. Online Computing Reviews Service

    Access critical reviews of Computing literature here

    Become a reviewer for Computing Reviews.

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in
    • Published in

      cover image ACM Conferences
      SIGCSE '15: Proceedings of the 46th ACM Technical Symposium on Computer Science Education
      February 2015
      766 pages
      ISBN:9781450329668
      DOI:10.1145/2676723

      Copyright © 2015 ACM

      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      • Published: 24 February 2015

      Permissions

      Request permissions about this article.

      Request Permissions

      Check for updates

      Qualifiers

      • research-article

      Acceptance Rates

      SIGCSE '15 Paper Acceptance Rate105of289submissions,36%Overall Acceptance Rate1,595of4,542submissions,35%

      Upcoming Conference

      SIGCSE Virtual 2024

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader