02-14-2013
Which isn't enum? The options the function takes, or its values?
If it's being fed integers and takes enums, that's the problem. Or vice versa.
How to fix it depends on what it is. We can't really see your code from here.
8 More Discussions You Might Find Interesting
1. Programming
helo i have asked in exam what that what is the base type of
enum
options are given bewlo
(1) long int
(2) short int
(3) signed int
(4) unsigned int
can u tell me what is the exact answer from the above option
Regards,
Amit (1 Reply)
Discussion started by: amitpansuria
1 Replies
2. IP Networking
Hi Guys,
This is really really urgent. Am looking out for some quick answers.
I'm developing a DNS Resolver client that interprets DNS Query repsonses & pass on the needful to DNS applications.
When an ENUM query(modified to an nslookup naptr query) is issued & an NAPTR RR(Resource Record)... (1 Reply)
Discussion started by: smanu
1 Replies
3. Filesystems, Disks and Memory
Hi there,
Here I have an old HP LC3 server from a client of ours.
The server was running in Raid1 Mirror mode.
Yesterday the server didn't boot anymore and now
I have concluded that 1 drive is damaged.
I pulled it out so it can boot from the "good" one.
Unfortuanally this didn't work.
I... (3 Replies)
Discussion started by: severt
3 Replies
4. HP-UX
Hi,
I am trying to start the apache server on 11i for Coverity Prevent using following command:
# cov-start-gui --datadir /qa_home/coverity/data_dir-4.3.0
cov-internal-httpd not running.
For further information, see '/qa_home/coverity/data_dir-4.3.0/logs/error_log'
#
the error_log... (0 Replies)
Discussion started by: prits31
0 Replies
5. Programming
#include <iostream>
#include <stdio.h>
using namespace std;
typedef struct A
{
enum a{ red,blue,green}a;
}obj11;
obj11 obj1;
int main()
{
//obj1.a=red; // how to set variable ?
cout<<"sizeof struct is n"<<sizeof(obj1);
cout<<"obj1.a is"<<obj1.a;
if... (1 Reply)
Discussion started by: crackthehit007
1 Replies
6. Programming
Say I have a list of enumerations I wish to use to select a variable at compile-time:
enum pins
{
PIN_A=1,
PIN_B=7,
PIN_C=6,
}
int VAR1, VAR2, VAR3, VAR4, VAR5, VAR6, VAR7;
#define PIN_TO_VAR(NUM) VAR ## NUM
int main(void)
{
PIN_TO_VAR(PIN_A)=32;... (2 Replies)
Discussion started by: Corona688
2 Replies
7. Programming
I am trying to implement a spare array in C that would be referenced by regular integers.
Right away: define array for maximum possible index elements completely is not what I trying to get!!!
It should be a construction that would have just 2 elements if I need to have just two indexes, like... (8 Replies)
Discussion started by: alex_5161
8 Replies
8. Shell Programming and Scripting
Hi! All
I am just wondering solution to use FS if file fields are separated by whitespace (one or more spaces ), tab and comma, How to use FS ?
finally I want to print all columns as tab separated
look at my file here tagged
130, US 121337 30.530 -58.900 1941 1 25 19.50 ... (5 Replies)
Discussion started by: Akshay Hegde
5 Replies
LEARN ABOUT CENTOS
perl::critic::policy::valuesandexpressions::prohibitmismatchedop
Perl::Critic::Policy::ValuesAndExpressions::ProhibitMismUsereContributedPerl::Critic::Policy::ValuesAndExpressions::ProhibitMismatchedOperators(3)
NAME
Perl::Critic::Policy::ValuesAndExpressions::ProhibitMismatchedOperators - Don't mix numeric operators with string operands, or vice-versa.
AFFILIATION
This Policy is part of the core Perl::Critic distribution.
DESCRIPTION
Using the wrong operator type for a value can obscure coding intent and possibly lead to subtle errors. An example of this is mixing a
string equality operator with a numeric value, or vice-versa.
if ($foo == 'bar') {} #not ok
if ($foo eq 'bar') {} #ok
if ($foo eq 123) {} #not ok
if ($foo == 123) {} #ok
CONFIGURATION
This Policy is not configurable except for the standard options.
NOTES
If warnings are enabled, the Perl interpreter usually warns you about using mismatched operators at run-time. This Policy does essentially
the same thing, but at author-time. That way, you can find out about them sooner.
AUTHOR
Peter Guzis <pguzis@cpan.org>
COPYRIGHT
Copyright (c) 2006-2011 Peter Guzis. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. The full text of this license
can be found in the LICENSE file included with this module.
perl v5.16.3 2014Perl::Critic::Policy::ValuesAndExpressions::ProhibitMismatchedOperators(3)