Questions tagged [standards]

Standards are officially published or well agreed upon formats, procedures, or protocols. They allow individuals or organizations to collaborate by setting ground rules or boundaries. Standards often come with a set of preconditions or assumptions, which allow collaborators to take those conditions or assumptions as ground truth.

The concept of "standard" is at least as old as the Roman Empire, where the standard was a rod of wood often decorated with a headpiece or banner and carried at the front of an army's march. This one rod was used to establish a common length for contructing camps and buildings. By using the same length, workers constructing a door could operate independently of other workers constructing a door frame. And when the pieces were brought together, they fit.

Modern standards are often created by jurisdiction-based entities like national standards organizations (like ANSI in the USA) or the International Standards Organization (ISO).

3387 questions
3
votes
3 answers

Use $_POST["x"] directly or to copy to a local variable and then use?

Consider the following pair of snippets, both do the same essentially.
delete
3
votes
2 answers

Are the java.util.* packages only meant for utility classes?

I am programming in Java and was told to refactor some code to coding standards. I was told that util packages are meant for static utility classes and not application functionality. Is this correct? What exactly does this mean? Also, considering…
Andrew Campbell
  • 17,665
  • 2
  • 16
  • 25
3
votes
1 answer

Why does the keyword `explicit` not apply to function parameters?

In certain cases, implicit type conversion may not be desired. For example: #include using namespace std; void f(bool) {} void f(string) {} int main() { auto p = "hello"; f(p); // Oops!!! Call void f(bool); rather than void…
xmllmx
  • 39,765
  • 26
  • 162
  • 323
3
votes
1 answer

C++ Overload resolution ambiguous - GCC

I'm trying to understand, why GCC chooses f(char, A &var) for overload-resolution in the code below: template struct A { }; template struct A { static_assert(sizeof(C) > 8, "Assertion in A"); }; template…
Shivam
  • 2,134
  • 1
  • 18
  • 28
3
votes
2 answers

Can web pages be made future proof?

I understand that makes the browser render the page in standards mode, but that does not prevent your page from breaking when say, HTML 6 comes out. Instead of making standards so generic, why don't they make it so that at the top…
AxiomaticNexus
  • 6,190
  • 3
  • 41
  • 61
3
votes
2 answers

Laying out graphics in RTF

I'm interested how to construct certain kinds of layout in RTF documents, ideally using techniques that do not depend only on the most recent RTF standards, and that are "native", i.e., they do not involve embedding other representations, like…
Charles Stewart
  • 11,661
  • 4
  • 46
  • 85
3
votes
1 answer

Convention for public facing site's dev server

I come from an enterprise environment where I primarily work on internal web applications. I'm interested in doing some web development on the side, but I have a few questions regarding how things are typically done outside an enterprise. At work,…
Jeff
  • 2,283
  • 9
  • 32
  • 50
3
votes
1 answer

Choosing licensing statement for an open standard/specification

I've started to write a file format specification for a domain-specific data type. My goal is to improve interoperability between a large number of data providers and search algorithms. I want the result to be available for use, patent-free and…
Andrew Dalke
  • 14,889
  • 4
  • 39
  • 54
3
votes
0 answers

Good vs bad practice in coding

I've been working in this company for about 8 months now and i'd like some advice how to tell my collegues that what they write is bad practice. Let me give a little introduction first. The company im working at allows its customers to setup…
Robin
  • 527
  • 5
  • 16
3
votes
4 answers

Is there an ISO-Prolog reference implementation?

Java has a reference implementation. Does ISO-Prolog have a reference implementation? I do have INCITS/ISO/IEC 13211-1:1995 (R 2007) so no need to suggest that. EDIT Of note: Conformity Testing I: Syntax
Guy Coder
  • 24,501
  • 8
  • 71
  • 136
3
votes
1 answer

Weird behaviour of prefix and postfix operators

Why is the first expression allowed, but the second not: void test() { int a; ++a = getSomeInt(); a++ = getSomeInt(); } I mean, why its forbidden for the second one to be an lvalue? The second one makes sense and the first not. In the…
aaljovic
  • 81
  • 1
  • 1
  • 7
3
votes
3 answers

Are file scoped static objects zero initialized before static initialization occurs for the owning translation unit?

In file maybe_use_foo.cpp: namespace { class Foo { /* ... */ }; Foo* const the_foo = new Foo; } void funtion_callable_from_another_tu_during_process_wide_initialization() { // If we haven't yet run static initialization for this TU, …
acm
  • 12,183
  • 5
  • 39
  • 68
3
votes
1 answer

SAML Standard for Service Provider Attribute Mapping

We run a Shibboleth Identity Provider, and have been increasingly asked to integrate with applications using non-Shibboleth SAML solutions, and encountering difficulty with regard to attribute naming. With a pure Shibboleth IdP & SP relationship, I…
HOG Wild
  • 208
  • 1
  • 8
3
votes
3 answers

Naming function parameters the same as class members

This is something I do quite commonly when I program C++, and I've been wondering for a while if its a "bad" habit (Is this behaviour standardized?) Lets say I have a class: Class Foo { public: Foo(int x) { //this->x is the member "x" of…
Brad
  • 10,015
  • 17
  • 54
  • 77
3
votes
2 answers

Fundamental reasons for not allowing multi-arguments operator[] in C++

Currently, we can only overload operator[] with exactly one argument. I would like to know if there is a fundamental reason why the standard does not allow to overload operator[] for several arguments ? Are there propoposals in this way for C++17…
Vincent
  • 57,703
  • 61
  • 205
  • 388